Support the monitor interface on Windows as well

This change required sacrificing both code cleanliness and the specific
error reports from perror(). Those could have been kept with a portable
wrapper, but that's too much work. We'll do it if unforseen errors
arise.
This commit is contained in:
2020-12-04 17:22:54 +01:00
parent 85dcdd4cc5
commit 26024de866
3 changed files with 24 additions and 29 deletions

View File

@@ -104,9 +104,7 @@ int main() {
TransportManager::init();
BuddyManager::init();
GroupManager::init();
#ifndef _WIN32
Monitor::init();
#endif
Database::open();
switch (settings::EVENTMODE) {
@@ -125,9 +123,7 @@ int main() {
shardServer = new CNShardServer(settings::SHARDPORT);
shardThread = new std::thread(startShard, (CNShardServer*)shardServer);
#ifndef _WIN32
monitorThread = new std::thread(Monitor::start, nullptr);
#endif
loginServer.start();