#include <config.h>
-#include <libpspp/message.h>
+#include "message.h"
+#include "msg-locator.h"
#include <assert.h>
#include <stdarg.h>
/* Message handler as set by msg_init(). */
static void (*msg_handler) (const struct msg *);
-static void (*msg_location) (struct msg_locator *);
-
/* Disables emitting messages if positive. */
static int messages_disabled;
}
void
-msg_init ( void (*handler) (const struct msg *),
- void (*location) (struct msg_locator *) )
+msg_init ( void (*handler) (const struct msg *) )
{
msg_handler = handler;
- msg_location = location;
}
void
void
msg_emit (struct msg *m)
{
- msg_location (&m->where);
+ get_msg_location (&m->where);
if (!messages_disabled)
msg_handler (m);
free (m->text);