From d8d71df30164d13cd325b566292683f7da8cca7f Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Thu, 19 Sep 2013 14:40:46 -0400 Subject: Build fix for network ID remap hack. --- node/NodeConfig.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/node/NodeConfig.cpp b/node/NodeConfig.cpp index 4462d0e2..12509e9f 100644 --- a/node/NodeConfig.cpp +++ b/node/NodeConfig.cpp @@ -73,7 +73,8 @@ NodeConfig::NodeConfig(const RuntimeEnvironment *renv,const char *authToken,unsi memcpy(_controlSocketKey,csk,32); } - std::map networksDotD(Utils::listDirectory((_r->homePath + ZT_PATH_SEPARATOR_S + "networks.d").c_str())); + std::string networksFolder(_r->homePath + ZT_PATH_SEPARATOR_S + "networks.d"); + std::map networksDotD(Utils::listDirectory(networksFolder.c_str())); std::set nwids; for(std::map::iterator d(networksDotD.begin());d!=networksDotD.end();++d) { if (!d->second) { @@ -86,7 +87,7 @@ NodeConfig::NodeConfig(const RuntimeEnvironment *renv,const char *authToken,unsi // config file. New one will be created. if (nwid == 0x6c92786fee000001ULL) { nwid = 0xbc8f9a8ee3000001ULL; - Utils::rm(networksDotD + ZT_PATH_SEPARATOR_S + d->first); + Utils::rm((networksFolder + ZT_PATH_SEPARATOR_S + d->first).c_str()); } if (nwid > 0) -- cgit v1.2.3