mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-01-22 04:04:16 +00:00
log to file if daemon only
This commit is contained in:
parent
334c92bb49
commit
8aaaf26a9e
19
Daemon.cpp
19
Daemon.cpp
@ -67,13 +67,18 @@ namespace i2p
|
|||||||
// initialize log
|
// initialize log
|
||||||
if (isLogging)
|
if (isLogging)
|
||||||
{
|
{
|
||||||
std::string logfile_path = i2p::util::filesystem::GetDataDir().string();
|
if (isDaemon)
|
||||||
#ifndef _WIN32
|
{
|
||||||
logfile_path.append("/debug.log");
|
std::string logfile_path = i2p::util::filesystem::GetDataDir().string();
|
||||||
#else
|
#ifndef _WIN32
|
||||||
logfile_path.append("\\debug.log");
|
logfile_path.append("/debug.log");
|
||||||
#endif
|
#else
|
||||||
StartLog (logfile_path);
|
logfile_path.append("\\debug.log");
|
||||||
|
#endif
|
||||||
|
StartLog (logfile_path);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
StartLog (""); // write to stdout
|
||||||
}
|
}
|
||||||
|
|
||||||
d.httpServer = new i2p::util::HTTPServer(i2p::util::config::GetArg("-httpport", 7070));
|
d.httpServer = new i2p::util::HTTPServer(i2p::util::config::GetArg("-httpport", 7070));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user