Fixed compilation under Windows.

Signed-off-by: Alexander Shaduri <ashaduri@gmail.com>
This commit is contained in:
Alexander Shaduri
2022-02-04 11:46:35 +04:00
parent d508db41c3
commit 9852b4de81
+5
View File
@@ -253,8 +253,13 @@ bool Cmdex::execute()
bool Cmdex::try_stop(hz::signal_t sig)
{
DBG_FUNCTION_ENTER_MSG;
#ifdef _WIN32
if (!this->running_ || this->pid_ == 0)
return false;
#else
if (!this->running_ || this->pid_ <= 0)
return false;
#endif
// other variants: SIGHUP(1) (terminal closed), SIGINT(2) (Ctrl-C),
// SIGKILL(9) (kill).