From def35532a61d90ba9e626bf54a2fdf18e6c8c840 Mon Sep 17 00:00:00 2001 From: Juan Jose Garcia Ripoll Date: Wed, 19 Jan 2011 22:26:42 +0100 Subject: [PATCH] Fixes in unixint.c (J James) * Return without a value in a C function. * Conditionalize a text message that is only used with sigprocmask. * Replace a use of mysignal with signal() --- src/c/unixint.d | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/c/unixint.d b/src/c/unixint.d index 3f7f500d7..259e4ce1b 100644 --- a/src/c/unixint.d +++ b/src/c/unixint.d @@ -258,7 +258,7 @@ handler_fn_protype(lisp_signal_handler, int sig, siginfo_t *info, void *aux) cl_env_ptr the_env = ecl_process_env(); /* The lisp environment might not be installed. */ if (the_env == NULL) - return; + return Cnil; #if defined(ECL_THREADS) && !defined(ECL_MS_WINDOWS_HOST) if (sig == ecl_get_option(ECL_OPT_THREAD_INTERRUPT_SIGNAL)) { return pop_signal(the_env); @@ -542,12 +542,14 @@ handler_fn_protype(sigsegv_handler, int sig, siginfo_t *info, void *aux) "\n;;;\n;;; Stack overflow.\n" ";;; Jumping to the outermost toplevel prompt\n" ";;;\n\n"; +#ifndef HAVE_SIGPROCMASK static const char *segv_msg = "\n;;;\n" ";;; Detected access to protected memory, " "also kwown as 'segmentation fault'.\n" ";;; Jumping to the outermost toplevel prompt\n" ";;;\n\n"; +#endif cl_env_ptr the_env; reinstall_signal(sig, sigsegv_handler); if (!ecl_get_option(ECL_OPT_BOOTED)) { @@ -688,7 +690,7 @@ si_catch_signal(cl_object code, cl_object boolean) for (i = 0; known_signals[i].code >= 0; i++) { if (known_signals[i].code == code_int) { if (Null(boolean)) - mysignal(code_int, SIG_DFL); + signal(code_int, SIG_DFL); else if (code_int == SIGSEGV) mysignal(code_int, sigsegv_handler); #ifdef SIGBUS