Mercurial > hg > orthanc
diff OrthancServer/main.cpp @ 137:0e97abc7b950
fix of a bug in older versions of sqlite
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 10 Oct 2012 13:13:14 +0200 |
parents | fe180eae201d |
children | 00604c758004 |
line wrap: on
line diff
--- a/OrthancServer/main.cpp Tue Oct 09 18:21:01 2012 +0200 +++ b/OrthancServer/main.cpp Wed Oct 10 13:13:14 2012 +0200 @@ -113,6 +113,8 @@ << "<https://code.google.com/p/orthanc/wiki/OrthancCookbook>." << std::endl << std::endl << "Command-line options:" << std::endl + << " --verbose\t\tbe verbose in logs" << std::endl + << " --trace\t\thighest verbosity in logs (for debug)" << std::endl << " --help\t\tdisplay this help and exit" << std::endl << " --version\t\toutput version information and exit" << std::endl << " --logdir=[dir]\tdirectory where to store the log files" << std::endl @@ -142,6 +144,8 @@ { // Initialize Google's logging library. FLAGS_logtostderr = true; + FLAGS_minloglevel = 1; + FLAGS_v = 0; for (int i = 1; i < argc; i++) { @@ -157,6 +161,17 @@ return 0; } + if (std::string(argv[i]) == "--verbose") + { + FLAGS_minloglevel = 0; + } + + if (std::string(argv[i]) == "--trace") + { + FLAGS_minloglevel = 0; + FLAGS_v = 1; + } + if (boost::starts_with(argv[i], "--logdir=")) { FLAGS_logtostderr = false; @@ -235,11 +250,11 @@ httpServer.Start(); dicomServer.Start(); - LOG(INFO) << "The server has started"; + LOG(WARNING) << "Orthanc has started"; Toolbox::ServerBarrier(); // Stop - LOG(INFO) << "The server is stopping"; + LOG(WARNING) << "Orthanc is stopping"; } storeScp.Done();