diff options
author | Haru <haru@dotalux.com> | 2018-06-25 20:46:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-06-25 20:46:30 +0200 |
commit | a70955368115603b5c9856ecb24e25430293d1b7 (patch) | |
tree | eff1b4ae55ae03f82846e7176f2bbc9e59f0876d /src/common/console.c | |
parent | ce52b50c244e9223c398b70575616e88414446ce (diff) | |
parent | 9852b6ac5eea101aa71d80b01a41d46cb4add5d1 (diff) | |
download | hercules-a70955368115603b5c9856ecb24e25430293d1b7.tar.gz hercules-a70955368115603b5c9856ecb24e25430293d1b7.tar.bz2 hercules-a70955368115603b5c9856ecb24e25430293d1b7.tar.xz hercules-a70955368115603b5c9856ecb24e25430293d1b7.zip |
Merge pull request #2106 from MishimaHaruna/shutdownfix
Fix the shutdown callback (2015 regression)
Diffstat (limited to 'src/common/console.c')
-rw-r--r-- | src/common/console.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/common/console.c b/src/common/console.c index 0b0a900f6..e7edd7e1e 100644 --- a/src/common/console.c +++ b/src/common/console.c @@ -133,7 +133,10 @@ int console_parse_key_pressed(void) **/ CPCMD_C(exit, server) { - core->runflag = 0; + if (core->shutdown_callback != NULL) + core->shutdown_callback(); + else + core->runflag = CORE_ST_STOP; } /** |