mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
* use IsDefault() to check explicitly set values
This commit is contained in:
parent
70f72a78f6
commit
7a0a45e9d2
2 changed files with 3 additions and 3 deletions
|
@ -83,14 +83,14 @@ namespace i2p
|
|||
LogPrint(eLogDebug, "FS: data directory: ", datadir);
|
||||
|
||||
uint16_t port; i2p::config::GetOption("port", port);
|
||||
if (port)
|
||||
if (!i2p::config::IsDefault("port"))
|
||||
{
|
||||
LogPrint(eLogInfo, "Daemon: accepting incoming connections at port ", port);
|
||||
i2p::context.UpdatePort (port);
|
||||
}
|
||||
|
||||
std::string host; i2p::config::GetOption("host", host);
|
||||
if (host != "0.0.0.0")
|
||||
if (!i2p::config::IsDefault("host"))
|
||||
{
|
||||
LogPrint(eLogInfo, "Daemon: setting address for incoming connections to ", host);
|
||||
i2p::context.UpdateAddress (boost::asio::ip::address::from_string (host));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue