diff options
| author | Adam Ierymenko <adam.ierymenko@zerotier.com> | 2015-11-13 12:14:28 -0800 |
|---|---|---|
| committer | Adam Ierymenko <adam.ierymenko@zerotier.com> | 2015-11-13 12:14:28 -0800 |
| commit | 0d9f33dc4f14b7339d1893e79772a8e49b4821eb (patch) | |
| tree | e7b3e1ee8ec92d57ce71482c64738f4211e5d9ff /node/Cluster.cpp | |
| parent | 90f9415107fded22346bfa94f98afa73c6c2811e (diff) | |
| download | infinitytier-0d9f33dc4f14b7339d1893e79772a8e49b4821eb.tar.gz infinitytier-0d9f33dc4f14b7339d1893e79772a8e49b4821eb.zip | |
Fix: (1) Windows stack overflow due to buffer too large in peer deserialize, (2) clean up some other stuff seen during debugging and reduce the sizes of some buffers due to Windows small stack size, (3) remove a redundant try/catch.
Diffstat (limited to 'node/Cluster.cpp')
| -rw-r--r-- | node/Cluster.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/node/Cluster.cpp b/node/Cluster.cpp index af9ab854..fa9a1611 100644 --- a/node/Cluster.cpp +++ b/node/Cluster.cpp @@ -628,7 +628,7 @@ void Cluster::doPeriodicTasks() } alive.append((uint64_t)now); alive.append((uint64_t)0); // TODO: compute and send load average - alive.append((uint64_t)RR->topology->countActive()); + alive.append((uint64_t)RR->topology->countActive(now)); alive.append((uint64_t)0); // unused/reserved flags alive.append((uint8_t)_zeroTierPhysicalEndpoints.size()); for(std::vector<InetAddress>::const_iterator pe(_zeroTierPhysicalEndpoints.begin());pe!=_zeroTierPhysicalEndpoints.end();++pe) @@ -769,7 +769,7 @@ void Cluster::status(ZT_ClusterStatus &status) const s->y = _y; s->z = _z; s->load = 0; // TODO - s->peers = RR->topology->countActive(); + s->peers = RR->topology->countActive(now); for(std::vector<InetAddress>::const_iterator ep(_zeroTierPhysicalEndpoints.begin());ep!=_zeroTierPhysicalEndpoints.end();++ep) { if (s->numZeroTierPhysicalEndpoints >= ZT_CLUSTER_MAX_ZT_PHYSICAL_ADDRESSES) // sanity check break; |
