core: fix use of uninitialised data

This commit is contained in:
moneromooo-monero 2018-03-18 23:36:20 +00:00
parent 5710edf040
commit b1398fff40
No known key found for this signature in database
GPG Key ID: 686F07454D6CEFC3
2 changed files with 4 additions and 2 deletions

View File

@ -200,6 +200,7 @@ namespace cryptonote
MAINNET = 0,
TESTNET,
STAGENET,
FAKECHAIN
FAKECHAIN,
UNDEFINED = 255
};
}

View File

@ -171,7 +171,8 @@ namespace cryptonote
m_last_json_checkpoints_update(0),
m_disable_dns_checkpoints(false),
m_threadpool(tools::threadpool::getInstance()),
m_update_download(0)
m_update_download(0),
m_nettype(UNDEFINED)
{
m_checkpoints_updating.clear();
set_cryptonote_protocol(pprotocol);