[win32] drop service code, fix start with daemon option. Throw notification when unable to parse config

Signed-off-by: R4SAS <r4sas@i2pmail.org>
This commit is contained in:
R4SAS 2021-03-11 14:39:33 +03:00
parent 7c0b0a4e3e
commit cb8651ec68
7 changed files with 21 additions and 556 deletions

View file

@ -102,8 +102,13 @@ namespace util
if (logclftime)
i2p::log::Logger().SetTimeFormat ("[%d/%b/%Y:%H:%M:%S %z]");
#ifdef WIN32_APP
// Win32 app with GUI supports only logging to file
logs = "file";
#else
if (isDaemon && (logs == "" || logs == "stdout"))
logs = "file";
#endif
i2p::log::Logger().SetLogLevel(loglevel);
if (logstream) {
@ -123,7 +128,7 @@ namespace util
// use stdout -- default
}
LogPrint(eLogInfo, "i2pd v", VERSION, " starting");
LogPrint(eLogNone, "i2pd v", VERSION, " starting");
LogPrint(eLogDebug, "FS: main config file: ", config);
LogPrint(eLogDebug, "FS: data directory: ", datadir);