1
0
mirror of https://github.com/imgproxy/imgproxy.git synced 2025-01-08 10:45:04 +02:00
imgproxy/gliblog/gliblog.c
2022-08-01 20:26:34 +06:00

22 lines
502 B
C

#include "gliblog.h"
static GLogLevelFlags all_levels =
G_LOG_FLAG_RECURSION |
G_LOG_FLAG_FATAL |
G_LOG_LEVEL_ERROR |
G_LOG_LEVEL_CRITICAL |
G_LOG_LEVEL_WARNING;
void
log_handler(const gchar *log_domain, GLogLevelFlags log_level,
const gchar *message, gpointer user_data) {
logGLib((char *)log_domain, log_level, (char *)message);
}
void
glib_log_configure() {
g_log_set_handler (NULL, all_levels, log_handler, NULL);
g_log_set_handler ("VIPS", all_levels, log_handler, NULL);
}