1
0
mirror of https://github.com/PurpleI2P/i2pd.git synced 2025-01-22 08:14:15 +00:00

fixed #696. set netid before context::Init

This commit is contained in:
orignal 2016-11-01 13:34:19 -04:00
parent 7934974d92
commit 2d513277f2

View File

@ -121,6 +121,9 @@ namespace i2p
bool precomputation; i2p::config::GetOption("precomputation.elgamal", precomputation);
i2p::crypto::InitCrypto (precomputation);
int netID; i2p::config::GetOption("netid", netID);
i2p::context.SetNetID (netID);
i2p::context.Init ();
bool ipv6; i2p::config::GetOption("ipv6", ipv6);
@ -144,9 +147,6 @@ namespace i2p
uint16_t transitTunnels; i2p::config::GetOption("limits.transittunnels", transitTunnels);
SetMaxNumTransitTunnels (transitTunnels);
int netID; i2p::config::GetOption("netid", netID);
i2p::context.SetNetID (netID);
bool isFloodfill; i2p::config::GetOption("floodfill", isFloodfill);
if (isFloodfill) {
LogPrint(eLogInfo, "Daemon: router will be floodfill");