1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-30 23:10:21 +02:00

abort on pre-boot throw without catch

* libguile/throw.c (pre_init_throw): Abort instead of exit in the error
  case.  Print out a message.
This commit is contained in:
Andy Wingo 2011-02-09 23:15:57 +01:00
parent c7c2d87547
commit e745064231

View file

@ -566,8 +566,10 @@ pre_init_throw (SCM k, SCM args)
return scm_at_abort (sym_pre_init_catch_tag, scm_cons (k, args)); return scm_at_abort (sym_pre_init_catch_tag, scm_cons (k, args));
else else
{ {
fprintf (stderr, "Throw without catch before boot:\n");
scm_handle_by_message_noexit (NULL, k, args); scm_handle_by_message_noexit (NULL, k, args);
exit (1); fprintf (stderr, "Aborting.\n");
abort ();
return SCM_BOOL_F; /* not reached */ return SCM_BOOL_F; /* not reached */
} }
} }