mirror of
https://github.com/matrix-construct/construct
synced 2024-12-28 00:14:07 +01:00
ircd: Add interrupt for server dtor.
This commit is contained in:
parent
97672ccc8f
commit
bcebeb420d
3 changed files with 9 additions and 0 deletions
|
@ -117,6 +117,8 @@ struct ircd::server::node
|
||||||
|
|
||||||
struct ircd::server::init
|
struct ircd::server::init
|
||||||
{
|
{
|
||||||
|
void interrupt();
|
||||||
|
|
||||||
init();
|
init();
|
||||||
~init() noexcept;
|
~init() noexcept;
|
||||||
};
|
};
|
||||||
|
|
|
@ -281,6 +281,7 @@ try
|
||||||
// Any deinits which have to be done with all subsystems intact
|
// Any deinits which have to be done with all subsystems intact
|
||||||
const unwind shutdown{[&]
|
const unwind shutdown{[&]
|
||||||
{
|
{
|
||||||
|
_server_.interrupt();
|
||||||
_client_.interrupt();
|
_client_.interrupt();
|
||||||
}};
|
}};
|
||||||
|
|
||||||
|
|
|
@ -36,6 +36,12 @@ noexcept
|
||||||
ircd::server::nodes.clear();
|
ircd::server::nodes.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
ircd::server::init::interrupt()
|
||||||
|
{
|
||||||
|
ircd::server::nodes.clear();
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// server
|
// server
|
||||||
//
|
//
|
||||||
|
|
Loading…
Reference in a new issue