Function

GLibLogFunc

Declaration

void
(* GLogFunc) (
  const gchar* log_domain,
  GLogLevelFlags log_level,
  const gchar* message,
  gpointer user_data
)

Description [src]

Specifies the prototype of log handler functions.

The default log handler, g_log_default_handler(), automatically appends a new-line character to message when printing it. It is advised that any custom log handler functions behave similarly, so that logging calls in user code do not need modifying to add a new-line character to the message if the log handler is changed.

This is not used if structured logging is enabled; see Using Structured Logging.

Parameters

log_domain

Type: const gchar*

The log domain of the message.

The data is owned by the caller of the function.
The value is a NUL terminated UTF-8 string.
log_level

Type: GLogLevelFlags

The log level of the message (including the fatal and recursion flags).

message

Type: const gchar*

The message to process.

The data is owned by the caller of the function.
The value is a NUL terminated UTF-8 string.
user_data

Type: gpointer

User data, set in g_log_set_handler().

The argument can be NULL.
The data is owned by the caller of the function.