diff options
| author | Adam Ierymenko <adam.ierymenko@gmail.com> | 2015-03-18 16:10:48 -0700 |
|---|---|---|
| committer | Adam Ierymenko <adam.ierymenko@gmail.com> | 2015-03-18 16:10:48 -0700 |
| commit | a8a92c5b89b51f6786d6e5cb41a588197b6afabb (patch) | |
| tree | 9004ad82f5660f889635e5ccf5ede58be0f4922d /node/NetworkConfig.cpp | |
| parent | cea3f2815589f956f699ad589a66c9d09f406ee9 (diff) | |
| download | infinitytier-a8a92c5b89b51f6786d6e5cb41a588197b6afabb.tar.gz infinitytier-a8a92c5b89b51f6786d6e5cb41a588197b6afabb.zip | |
A whole lot of Sqlite netconf master work, and some fixes elsewhere in the code.
Diffstat (limited to 'node/NetworkConfig.cpp')
| -rw-r--r-- | node/NetworkConfig.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/node/NetworkConfig.cpp b/node/NetworkConfig.cpp index 98e1b0d8..e42b0299 100644 --- a/node/NetworkConfig.cpp +++ b/node/NetworkConfig.cpp @@ -44,6 +44,7 @@ SharedPtr<NetworkConfig> NetworkConfig::createTestNetworkConfig(const Address &s nc->_etWhitelist[0] |= 1; // allow all nc->_nwid = ZT_TEST_NETWORK_ID; nc->_timestamp = Utils::now(); + nc->_revision = 1; nc->_issuedTo = self; nc->_multicastLimit = ZT_MULTICAST_DEFAULT_LIMIT; nc->_allowPassiveBridging = false; @@ -108,6 +109,7 @@ void NetworkConfig::_fromDictionary(const Dictionary &d) throw std::invalid_argument("configuration contains zero network ID"); _timestamp = Utils::hexStrToU64(d.get(ZT_NETWORKCONFIG_DICT_KEY_TIMESTAMP).c_str()); + _revision = Utils::hexStrToU64(d.get(ZT_NETWORKCONFIG_DICT_KEY_REVISION,"1").c_str()); // older netconf masters don't send this, so default to 1 memset(_etWhitelist,0,sizeof(_etWhitelist)); std::vector<std::string> ets(Utils::split(d.get(ZT_NETWORKCONFIG_DICT_KEY_ALLOWED_ETHERNET_TYPES).c_str(),",","","")); |
