summaryrefslogtreecommitdiff
path: root/service
diff options
context:
space:
mode:
authorGrant Limberg <glimberg@gmail.com>2016-09-05 16:19:10 -0700
committerGrant Limberg <glimberg@gmail.com>2016-09-05 16:19:10 -0700
commit68a966fa5578a160fbd602cecf0e235b8df34e9f (patch)
treea0633b825180feef8c74f24b005db1ec3f320af4 /service
parent43b3ec4b1afa3c3833f1f61ec10c9f22bd5e7359 (diff)
parent3790ebe77a90cdaad629f275c2c4294694626733 (diff)
downloadinfinitytier-68a966fa5578a160fbd602cecf0e235b8df34e9f.tar.gz
infinitytier-68a966fa5578a160fbd602cecf0e235b8df34e9f.zip
Merge branch 'dev' of http://git.int.zerotier.com/ZeroTier/ZeroTierOne into dev
Diffstat (limited to 'service')
-rw-r--r--service/ControlPlane.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/service/ControlPlane.cpp b/service/ControlPlane.cpp
index 5ed6b8b7..a24e3eb4 100644
--- a/service/ControlPlane.cpp
+++ b/service/ControlPlane.cpp
@@ -165,7 +165,7 @@ static void _jsonAppend(unsigned int depth,std::string &buf,const ZT_VirtualNetw
static std::string _jsonEnumerate(unsigned int depth,const ZT_PeerPhysicalPath *pp,unsigned int count)
{
- char json[1024];
+ char json[2048];
char prefix[32];
if (depth >= sizeof(prefix)) // sanity check -- shouldn't be possible
@@ -183,14 +183,14 @@ static std::string _jsonEnumerate(unsigned int depth,const ZT_PeerPhysicalPath *
"%s\t\"address\": \"%s\",\n"
"%s\t\"lastSend\": %llu,\n"
"%s\t\"lastReceive\": %llu,\n"
- "%s\t\"active\": %s,\n"
+ "%s\t\"active\": true,\n"
"%s\t\"preferred\": %s,\n"
"%s\t\"trustedPathId\": %llu\n"
"%s}",
prefix,_jsonEscape(reinterpret_cast<const InetAddress *>(&(pp[i].address))->toString()).c_str(),
prefix,pp[i].lastSend,
prefix,pp[i].lastReceive,
- prefix,(pp[i].active == 0) ? "false" : "true",
+ prefix,
prefix,(pp[i].preferred == 0) ? "false" : "true",
prefix,pp[i].trustedPathId,
prefix);
@@ -201,7 +201,7 @@ static std::string _jsonEnumerate(unsigned int depth,const ZT_PeerPhysicalPath *
static void _jsonAppend(unsigned int depth,std::string &buf,const ZT_Peer *peer)
{
- char json[1024];
+ char json[2048];
char prefix[32];
if (depth >= sizeof(prefix)) // sanity check -- shouldn't be possible