summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRoman Smrž <roman.smrz@seznam.cz>2021-11-29 23:04:42 +0100
committerRoman Smrž <roman.smrz@seznam.cz>2021-11-29 23:04:42 +0100
commitd9ddd8746ca83f361ec7ffb9f7146f6a23553b93 (patch)
treee710866642511b70e83b28fe4a903e034f1f00bc /src
parent53f4c26c4682a951e084415a594fcb8d9494033f (diff)
Server: finalize services before destroying peers and other data
Diffstat (limited to 'src')
-rw-r--r--src/network.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/network.h b/src/network.h
index b2cd8be..b1ecf86 100644
--- a/src/network.h
+++ b/src/network.h
@@ -162,7 +162,6 @@ struct Server::Priv
Identity self;
Bhv<LocalState> localState;
WatchedHead<LocalState> localHead;
- vector<unique_ptr<Service>> services;
thread threadListen;
thread threadAnnounce;
@@ -175,6 +174,9 @@ struct Server::Priv
int sock;
vector<in_addr> bcastAddresses;
+
+ // Start destruction with finalizing services
+ vector<unique_ptr<Service>> services;
};
}