Skip to content

Commit 471d727

Browse files
committed
fix(update_xnt): unset exitbypass after command_stop.sh in fn_update_localbuild
When the Xonotic server is not running during check-update, fn_update_localbuild starts it temporarily to read the version from the console log, then stops it. exitbypass=1 is set before command_stop.sh to prevent core_exit.sh from running mid-flow, but command_stop.sh does not unset exitbypass when skipping core_exit.sh. This caused the leaked exitbypass to bypass core_exit.sh at the end of command_check_update.sh, returning control to core_getopt.sh which then printed "Command did not exit correctly" and exited with code 2. Fix: unset exitbypass explicitly after command_stop.sh returns.
1 parent 3926115 commit 471d727

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lgsm/modules/update_xnt.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,9 @@ fn_update_localbuild() {
2929
exitbypass=1
3030
fn_sleep_time_5
3131
tmux -L "${socketname}" send-keys -t "${sessionname}" "version" C-m > /dev/null 2>&1
32+
exitbypass=1
3233
command_stop.sh
34+
unset exitbypass
3335
fn_firstcommand_reset
3436
fi
3537

0 commit comments

Comments
 (0)