0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-26 08:42:34 +01:00

construct: Ensure console_termstop executes in ctx.

This commit is contained in:
Jason Volk 2018-05-07 18:27:23 -07:00
parent 63d77c2392
commit 024912d072

View file

@ -162,8 +162,8 @@ const char *const termstop_message
*** This is a client and your commands will originate from the server itself.
***)"};
void
console_termstop()
static void
_console_termstop()
try
{
const unwind atexit([]
@ -194,6 +194,21 @@ catch(const std::exception &e)
};
}
void
console_termstop()
{
if(ctx::current)
return _console_termstop();
ircd::context
{
"console",
stack_sz,
_console_termstop,
ircd::context::DETACH
};
}
void
execute(const std::vector<std::string> lines)
try