|
@@ -47,7 +47,7 @@ const ZeroTier::MulticastGroup Network::BROADCAST(ZeroTier::MAC(0xffffffffffffUL
|
|
|
|
|
|
Network::Network(const RuntimeEnvironment *renv,uint64_t nwid,void *uptr) :
|
|
|
RR(renv),
|
|
|
- _uptr(uptr),
|
|
|
+ _uPtr(uptr),
|
|
|
_id(nwid),
|
|
|
_mac(renv->identity.address(),nwid),
|
|
|
_enabled(true),
|
|
@@ -89,7 +89,7 @@ Network::Network(const RuntimeEnvironment *renv,uint64_t nwid,void *uptr) :
|
|
|
if (!_portInitialized) {
|
|
|
ZT_VirtualNetworkConfig ctmp;
|
|
|
_externalConfig(&ctmp);
|
|
|
- _portError = RR->node->configureVirtualNetworkPort(_id,&_uptr,ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_UP,&ctmp);
|
|
|
+ _portError = RR->node->configureVirtualNetworkPort(_id,&_uPtr,ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_UP,&ctmp);
|
|
|
_portInitialized = true;
|
|
|
}
|
|
|
}
|
|
@@ -101,11 +101,11 @@ Network::~Network()
|
|
|
|
|
|
char n[128];
|
|
|
if (_destroyed) {
|
|
|
- RR->node->configureVirtualNetworkPort(_id,&_uptr,ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_DESTROY,&ctmp);
|
|
|
+ RR->node->configureVirtualNetworkPort(_id,&_uPtr,ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_DESTROY,&ctmp);
|
|
|
Utils::snprintf(n,sizeof(n),"networks.d/%.16llx.conf",_id);
|
|
|
RR->node->dataStoreDelete(n);
|
|
|
} else {
|
|
|
- RR->node->configureVirtualNetworkPort(_id,&_uptr,ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_DOWN,&ctmp);
|
|
|
+ RR->node->configureVirtualNetworkPort(_id,&_uPtr,ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_DOWN,&ctmp);
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -174,7 +174,7 @@ bool Network::applyConfiguration(const SharedPtr<NetworkConfig> &conf)
|
|
|
portInitialized = _portInitialized;
|
|
|
_portInitialized = true;
|
|
|
}
|
|
|
- _portError = RR->node->configureVirtualNetworkPort(_id,&_uptr,(portInitialized) ? ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_CONFIG_UPDATE : ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_UP,&ctmp);
|
|
|
+ _portError = RR->node->configureVirtualNetworkPort(_id,&_uPtr,(portInitialized) ? ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_CONFIG_UPDATE : ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_UP,&ctmp);
|
|
|
return true;
|
|
|
} else {
|
|
|
TRACE("ignored invalid configuration for network %.16llx (configuration contains mismatched network ID or issued-to address)",(unsigned long long)_id);
|
|
@@ -332,7 +332,7 @@ void Network::setEnabled(bool enabled)
|
|
|
_enabled = enabled;
|
|
|
ZT_VirtualNetworkConfig ctmp;
|
|
|
_externalConfig(&ctmp);
|
|
|
- _portError = RR->node->configureVirtualNetworkPort(_id,&_uptr,ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_CONFIG_UPDATE,&ctmp);
|
|
|
+ _portError = RR->node->configureVirtualNetworkPort(_id,&_uPtr,ZT_VIRTUAL_NETWORK_CONFIG_OPERATION_CONFIG_UPDATE,&ctmp);
|
|
|
}
|
|
|
}
|
|
|
|