mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2025-06-06 12:33:44 +02:00
Fix crash.
This commit is contained in:
parent
32f5a0ab18
commit
54fa73844c
1 changed files with 19 additions and 16 deletions
|
@ -1465,8 +1465,10 @@ void EmbeddedNetworkController::_request(
|
||||||
}
|
}
|
||||||
for(unsigned long i=0;i<memberCapabilities.size();++i) {
|
for(unsigned long i=0;i<memberCapabilities.size();++i) {
|
||||||
const uint64_t capId = OSUtils::jsonInt(memberCapabilities[i],0ULL) & 0xffffffffULL;
|
const uint64_t capId = OSUtils::jsonInt(memberCapabilities[i],0ULL) & 0xffffffffULL;
|
||||||
json *cap = capsById[capId];
|
std::map< uint64_t,json * >::const_iterator ctmp = capsById.find(capId);
|
||||||
if ((cap->is_object())&&(cap->size() > 0)) {
|
if (ctmp != capsById.end()) {
|
||||||
|
json *cap = ctmp->second;
|
||||||
|
if ((cap)&&(cap->is_object())&&(cap->size() > 0)) {
|
||||||
ZT_VirtualNetworkRule capr[ZT_MAX_CAPABILITY_RULES];
|
ZT_VirtualNetworkRule capr[ZT_MAX_CAPABILITY_RULES];
|
||||||
unsigned int caprc = 0;
|
unsigned int caprc = 0;
|
||||||
json &caprj = (*cap)["rules"];
|
json &caprj = (*cap)["rules"];
|
||||||
|
@ -1485,6 +1487,7 @@ void EmbeddedNetworkController::_request(
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
std::map< uint32_t,uint32_t > memberTagsById;
|
std::map< uint32_t,uint32_t > memberTagsById;
|
||||||
if (memberTags.is_array()) {
|
if (memberTags.is_array()) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue