summaryrefslogtreecommitdiff
path: root/src/uci.c
diff options
context:
space:
mode:
authorAargh Rai <aargh.rai+git@gmail.com>2026-07-24 09:32:54 +0530
committerAargh Rai <aargh.rai+git@gmail.com>2026-07-24 09:32:54 +0530
commit7d36403836511ab0745791ce98498cf5112633c1 (patch)
treebb1f998e3ce8fc99a8611dc64d578ca269c56b01 /src/uci.c
parente6cead853d66b4ea9ea8d9c6dba33e5a1720a99d (diff)
fixed the quit commandHEADmaster
Diffstat (limited to 'src/uci.c')
-rw-r--r--src/uci.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/uci.c b/src/uci.c
index cc16954..f842328 100644
--- a/src/uci.c
+++ b/src/uci.c
@@ -59,6 +59,7 @@ void handle_ipc(ipc_state_t *state) {
assert(signal < UCI_SIGNAL_COUNT);
if (signal == UCI_SIGNAL_NONE) return;
if (signal == UCI_SIGNAL_QUIT) {
+ ipc_state_set_event(state, EVENT_QUIT);
return;
}
if (signal == UCI_SIGNAL_GO) {
@@ -151,7 +152,9 @@ void handle_ipc(ipc_state_t *state) {
return;
}
if (signal == UCI_SIGNAL_STOP) {
- printf("uci stopping\n");
+ ipc_state_set_event(state, EVENT_ENGINE_STOP);
+ state->uci_state.signal = UCI_SIGNAL_NONE;
+ state->uci_state.current_state = UCI_STATE_IDLE;
return;
}
}