diff options
| author | Adam Ierymenko <adam.ierymenko@gmail.com> | 2013-10-17 16:49:31 -0400 |
|---|---|---|
| committer | Adam Ierymenko <adam.ierymenko@gmail.com> | 2013-10-17 16:49:31 -0400 |
| commit | e6eb65be0041bbf38be38219765bda0f92fae978 (patch) | |
| tree | f5b64e18ec49f4b9996ac8f4a9d7ec059c87e154 /node/Network.cpp | |
| parent | dd7758e33ef78a91fd0743a05c0741b71281460b (diff) | |
| download | infinitytier-e6eb65be0041bbf38be38219765bda0f92fae978.tar.gz infinitytier-e6eb65be0041bbf38be38219765bda0f92fae978.zip | |
Netconf support for ARP and NDP caching TTLs.
Diffstat (limited to 'node/Network.cpp')
| -rw-r--r-- | node/Network.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/node/Network.cpp b/node/Network.cpp index db84ada0..1c14e9f6 100644 --- a/node/Network.cpp +++ b/node/Network.cpp @@ -91,6 +91,8 @@ SharedPtr<Network> Network::newInstance(const RuntimeEnvironment *renv,uint64_t nw->_isOpen = false; nw->_emulateArp = false; nw->_emulateNdp = false; + nw->_arpCacheTtl = 0; + nw->_ndpCacheTtl = 0; nw->_multicastPrefixBits = ZT_DEFAULT_MULTICAST_PREFIX_BITS; nw->_multicastDepth = ZT_DEFAULT_MULTICAST_DEPTH; nw->_status = NETWORK_WAITING_FOR_FIRST_AUTOCONF; @@ -120,6 +122,8 @@ void Network::setConfiguration(const Network::Config &conf,bool saveToDisk) _isOpen = conf.isOpen(); _emulateArp = conf.emulateArp(); _emulateNdp = conf.emulateNdp(); + _arpCacheTtl = conf.arpCacheTtl(); + _ndpCacheTtl = conf.ndpCacheTtl(); _multicastPrefixBits = conf.multicastPrefixBits(); _multicastDepth = conf.multicastDepth(); @@ -153,6 +157,8 @@ void Network::setConfiguration(const Network::Config &conf,bool saveToDisk) _isOpen = false; _emulateArp = false; _emulateNdp = false; + _arpCacheTtl = 0; + _ndpCacheTtl = 0; _status = NETWORK_WAITING_FOR_FIRST_AUTOCONF; _lastConfigUpdate = 0; |
