Fix failure exit-code after pressing escape
WM_exit calls `exit(G.is_break == true)` which only makes sense in background mode, pressing escape sets `is_break` which isn't cleared, causing an error exit-code of 1 on exit.
This commit is contained in:
@@ -450,6 +450,9 @@ static void wait_for_console_key(void)
|
||||
|
||||
static int wm_exit_handler(bContext *C, const wmEvent *event, void *userdata)
|
||||
{
|
||||
/* Prevent a non-zero exit code (if escape was pressed by the user). */
|
||||
G.is_break = false;
|
||||
|
||||
WM_exit(C);
|
||||
|
||||
UNUSED_VARS(event, userdata);
|
||||
|
||||
Reference in New Issue
Block a user