From: Tomek Mrugalski Date: Thu, 6 Sep 2018 17:13:31 +0000 (+0200) Subject: [#25,!14] DHCP4,6 now use Deamon to set up default logger name X-Git-Tag: gitlab116_base~8 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3e4faff03fa6e3c12ce3d713e96ef0fd09d2b874;p=thirdparty%2Fkea.git [#25,!14] DHCP4,6 now use Deamon to set up default logger name --- diff --git a/src/bin/dhcp4/main.cc b/src/bin/dhcp4/main.cc index 6762eac8f6..5e98bdcfc9 100644 --- a/src/bin/dhcp4/main.cc +++ b/src/bin/dhcp4/main.cc @@ -134,7 +134,7 @@ main(int argc, char* argv[]) { // We need to initialize logging, in case any error messages are to be printed. // This is just a test, so we don't care about lockfile. setenv("KEA_LOCKFILE_DIR", "none", 0); - CfgMgr::instance().setDefaultLoggerName(DHCP4_ROOT_LOGGER_NAME); + Daemon::setDefaultLoggerName(DHCP4_ROOT_LOGGER_NAME); Daemon::loggerInit(DHCP4_ROOT_LOGGER_NAME, verbose_mode); // Check the syntax first. @@ -181,7 +181,7 @@ main(int argc, char* argv[]) { // It is important that we set a default logger name because this name // will be used when the user doesn't provide the logging configuration // in the Kea configuration file. - CfgMgr::instance().setDefaultLoggerName(DHCP4_ROOT_LOGGER_NAME); + Daemon::setDefaultLoggerName(DHCP4_ROOT_LOGGER_NAME); // Initialize logging. If verbose, we'll use maximum verbosity. Daemon::loggerInit(DHCP4_ROOT_LOGGER_NAME, verbose_mode); diff --git a/src/bin/dhcp6/main.cc b/src/bin/dhcp6/main.cc index c3f6f0f428..e90254d029 100644 --- a/src/bin/dhcp6/main.cc +++ b/src/bin/dhcp6/main.cc @@ -137,8 +137,8 @@ main(int argc, char* argv[]) { // We need to initialize logging, in case any error messages are to be printed. // This is just a test, so we don't care about lockfile. setenv("KEA_LOCKFILE_DIR", "none", 0); - CfgMgr::instance().setDefaultLoggerName(DHCP6_ROOT_LOGGER_NAME); - isc::process::Daemon::loggerInit(DHCP6_ROOT_LOGGER_NAME, verbose_mode); + Daemon::setDefaultLoggerName(DHCP6_ROOT_LOGGER_NAME); + Daemon::loggerInit(DHCP6_ROOT_LOGGER_NAME, verbose_mode); // Check the syntax first. Parser6Context parser; @@ -187,7 +187,7 @@ main(int argc, char* argv[]) { // It is important that we set a default logger name because this name // will be used when the user doesn't provide the logging configuration // in the Kea configuration file. - CfgMgr::instance().setDefaultLoggerName(DHCP6_LOGGER_NAME); + Daemon::setDefaultLoggerName(DHCP6_LOGGER_NAME); // Initialize logging. If verbose, we'll use maximum verbosity. Daemon::loggerInit(DHCP6_LOGGER_NAME, verbose_mode); diff --git a/src/lib/Makefile.am b/src/lib/Makefile.am index 30a5a9fd6d..1c462abd36 100644 --- a/src/lib/Makefile.am +++ b/src/lib/Makefile.am @@ -14,4 +14,4 @@ SUBDIRS += cql endif SUBDIRS += testutils hooks dhcp config stats asiodns dhcp_ddns eval \ - cfgrpt process dhcpsrv process http + cfgrpt process dhcpsrv http