Skip to content

Commit

Permalink
Fix deleting controller network member directory
Browse files Browse the repository at this point in the history
That trailing slash was making it not work.

ZT_HOME/controller.d/network/$nwid
  • Loading branch information
laduke committed Feb 22, 2024
1 parent d1a306a commit ac6d532
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion controller/FileDB.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ void FileDB::eraseNetwork(const uint64_t networkId)
char p[16384];
OSUtils::ztsnprintf(p,sizeof(p),"%s" ZT_PATH_SEPARATOR_S "%.16llx.json",_networksPath.c_str(),networkId);
OSUtils::rm(p);
OSUtils::ztsnprintf(p,sizeof(p),"%s" ZT_PATH_SEPARATOR_S "%.16llx" ZT_PATH_SEPARATOR_S "member",_networksPath.c_str(),(unsigned long long)networkId);
OSUtils::ztsnprintf(p,sizeof(p),"%s" ZT_PATH_SEPARATOR_S "%.16llx",_networksPath.c_str(),(unsigned long long)networkId);
OSUtils::rmDashRf(p);
_networkChanged(network,nullJson,true);
std::lock_guard<std::mutex> l(this->_online_l);
Expand Down

0 comments on commit ac6d532

Please sign in to comment.