diff options
author | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2009-06-16 15:39:09 +0400 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2009-06-16 15:39:09 +0400 |
commit | dc48e79c1507e1235a271b4a3763e9701651d2ab (patch) | |
tree | f4289c12007f953ade8cf096e1c4ec4eda2bacbc /src/main.c | |
parent | 53b1f011a3b34a40b08882e34083db820a815bab (diff) | |
download | rspamd-dc48e79c1507e1235a271b4a3763e9701651d2ab.tar.gz rspamd-dc48e79c1507e1235a271b4a3763e9701651d2ab.zip |
* Use own logging system to use static logging buffer instead of dynamically allocated one
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c index 03a2c01b9..9b8992d8b 100644 --- a/src/main.c +++ b/src/main.c @@ -193,6 +193,7 @@ config_logger (struct rspamd_main *rspamd, gboolean is_fatal) else { rspamd->cfg->log_fd = 2; } + rspamd_set_logger (file_log_function, rspamd->cfg); g_log_set_default_handler (file_log_function, rspamd->cfg); break; case RSPAMD_LOG_FILE: @@ -206,6 +207,7 @@ config_logger (struct rspamd_main *rspamd, gboolean is_fatal) } } else { + rspamd_set_logger (file_log_function, rspamd->cfg); g_log_set_default_handler (file_log_function, rspamd->cfg); } break; @@ -220,6 +222,7 @@ config_logger (struct rspamd_main *rspamd, gboolean is_fatal) } } else { + rspamd_set_logger (syslog_log_function, rspamd->cfg); g_log_set_default_handler (syslog_log_function, rspamd->cfg); } break; @@ -446,6 +449,7 @@ main (int argc, char **argv, char **env) /* First set logger to console logger */ cfg->log_fd = STDERR_FILENO; + rspamd_set_logger (file_log_function, rspamd->cfg); g_log_set_default_handler (file_log_function, cfg); #ifndef HAVE_SETPROCTITLE |