Commit 07851523 authored by Mukund Sivaraman's avatar Mukund Sivaraman
Browse files

[1704] Clarify why the null logger is used in logger_example

parent 6306feef
...@@ -281,7 +281,11 @@ int main(int argc, char** argv) { ...@@ -281,7 +281,11 @@ int main(int argc, char** argv) {
LoggerManager::readLocalMessageFile(argv[optind]); LoggerManager::readLocalMessageFile(argv[optind]);
} }
// Log a few messages to different loggers. // Log a few messages to different loggers. Here, we switch to using
// null interprocess sync objects for the loggers below as the
// logger example can be used as a standalone program (which may not
// have write access to a local state directory to create
// lockfiles).
isc::log::Logger logger_ex(ROOT_NAME); isc::log::Logger logger_ex(ROOT_NAME);
logger_ex.setInterprocessSync(new isc::util::InterprocessSyncNull("logger")); logger_ex.setInterprocessSync(new isc::util::InterprocessSyncNull("logger"));
isc::log::Logger logger_alpha("alpha"); isc::log::Logger logger_alpha("alpha");
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment