[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: No way out.
From: |
Marius Vollmer |
Subject: |
Re: No way out. |
Date: |
Wed, 07 Dec 2005 03:31:38 +0200 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
Bruce Korb <address@hidden> writes:
> On Sunday 04 December 2005 08:08 pm, Bruce Korb wrote:
>
>> Anyway, *real bugs* in Guile 1.7.2 are:
>>
>> 1. When an error is thrown, "exit" should be called with EXIT_FAILURE, not
>> 0.
>
> The problem here is that the doc for "gh_enter()" (and successors?) says
> that it does not return. It does. The error handling long jumps around
> my inner main and returns back to real main. Oops.
Oops, indeed! I fixed this.
My previous explanation was wrong: there should be no uncaught throws
unless there is some ither bug in Guile. scm_with_guile, which is now
the main function for initializing Guile, establishes a catch all (via
scm_with_continuation_barrier). However, that catch all does not exit
with pthread_exit, it simply makes scm_with_guile return NULL. Bad.
2005-12-07 Marius Vollmer <address@hidden>
Reported by Bruce Korb:
* init.c (invoke_main_func): Don't call exit here. Throws that are
only caught by scm_with_guile will bypass us and would cause
scm_boot_guile to return erroneously.
(scm_boot_guile): Expect scm_with_guile to return and call exit
here, passing it an appropriate exit code.
--
GPG: D5D4E405 - 2F9B BCCC 8527 692A 04E3 331E FAF8 226A D5D4 E405
Re: No way out., Marius Vollmer, 2005/12/06