From 17834b13a6b0699c999c898e57df9e0fd49e496c Mon Sep 17 00:00:00 2001 From: gambas Date: Sun, 28 Jan 2018 17:57:13 +0100 Subject: [PATCH] Don't call QUIT when terminating a task, it crashes. Just clean up the temporary directory and exit. [INTERPRETER] * BUG: Don't call QUIT when terminating a task, it crashes. Just clean up the temporary directory and exit. --- main/gbx/Makefile.am | 4 ++-- main/gbx/gbx.c | 2 +- main/gbx/gbx_c_task.c | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/main/gbx/Makefile.am b/main/gbx/Makefile.am index e7445ca06..d5ea660a3 100644 --- a/main/gbx/Makefile.am +++ b/main/gbx/Makefile.am @@ -7,9 +7,9 @@ gblib_LTLIBRARIES = gb.la libgbx_a_CFLAGS = -DGAMBAS_PATH="\"$(bindir)\"" $(AM_CFLAGS_OPT) -gbx3_LDADD = @C_LIB@ @GBX_THREAD_LIB@ libgbx.a @MATH_LIB@ @INTL_LIB@ @CONV_LIB@ @GETTEXT_LIB@ @DL_LIB@ @FFI_LIB@ @RT_LIB@ +gbx3_LDADD = @C_LIB@ @GBX_THREAD_LIB@ libgbx.a @MATH_LIB@ @INTL_LIB@ @CONV_LIB@ @GETTEXT_LIB@ @DL_LIB@ @FFI_LIB@ @RT_LIB@ gbx3_LDFLAGS = @LD_FLAGS@ @GBX_THREAD_LDFLAGS@ @INTL_LDFLAGS@ @CONV_LDFLAGS@ @GETTEXT_LDFLAGS@ @FFI_LDFLAGS@ @RT_LDFLAGS@ -gbx3_CFLAGS = -DGAMBAS_PATH="\"$(bindir)\"" $(AM_CFLAGS) +gbx3_CFLAGS = -DGAMBAS_PATH="\"$(bindir)\"" $(AM_CFLAGS) -flto gb_la_LIBADD = @C_LIB@ @GBX_THREAD_LIB@ @MATH_LIB@ @INTL_LIB@ @CONV_LIB@ @GETTEXT_LIB@ @DL_LIB@ @FFI_LIB@ @RT_LIB@ gb_la_LDFLAGS = -module @LD_FLAGS@ @INTL_LDFLAGS@ @CONV_LDFLAGS@ @GETTEXT_LDFLAGS@ @FFI_LDFLAGS@ @RT_LDFLAGS@ diff --git a/main/gbx/gbx.c b/main/gbx/gbx.c index c4bebd8c6..e64921ea4 100644 --- a/main/gbx/gbx.c +++ b/main/gbx/gbx.c @@ -472,7 +472,7 @@ int main(int argc, char *argv[]) MEMORY_exit(); fflush(NULL); - + return ret; } diff --git a/main/gbx/gbx_c_task.c b/main/gbx/gbx_c_task.c index c53afe34c..1ef91749c 100644 --- a/main/gbx/gbx_c_task.c +++ b/main/gbx/gbx_c_task.c @@ -252,8 +252,8 @@ static void prepare_task(CTASK *_object) static void exit_child(int ret) { - EXEC_quit_value = ret; - EXEC_quit(); + FILE_exit(); + _exit(ret); } static bool start_task(CTASK *_object)