aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRichard M. Stallman2006-03-11 15:19:31 +0000
committerRichard M. Stallman2006-03-11 15:19:31 +0000
commit88019a632801faf4b322b997971658a83274f33d (patch)
treea62dd49f70d3479e6b525b93ea2c80f66456cf64 /src
parentf7878d663bd4f3f4b6b8f3402f2e33224dfcc3cb (diff)
downloademacs-88019a632801faf4b322b997971658a83274f33d.tar.gz
emacs-88019a632801faf4b322b997971658a83274f33d.zip
(unwind_to_catch): Call x_fully_uncatch_errors.
(internal_condition_case_1, internal_condition_case_2): Abort if within unclosed x_catch_errors.
Diffstat (limited to 'src')
-rw-r--r--src/eval.c20
1 files changed, 17 insertions, 3 deletions
diff --git a/src/eval.c b/src/eval.c
index a84948981f4..435667e4d50 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -1259,6 +1259,10 @@ unwind_to_catch (catch, value)
1259 } 1259 }
1260 while (! last_time); 1260 while (! last_time);
1261 1261
1262 /* If x_catch_errors was done, turn it off now.
1263 (First we give unbind_to a chance to do that.) */
1264 x_fully_uncatch_errors ();
1265
1262 byte_stack_list = catch->byte_stack; 1266 byte_stack_list = catch->byte_stack;
1263 gcprolist = catch->gcpro; 1267 gcprolist = catch->gcpro;
1264#ifdef DEBUG_GCPRO 1268#ifdef DEBUG_GCPRO
@@ -1435,10 +1439,10 @@ internal_condition_case (bfun, handlers, hfun)
1435 struct catchtag c; 1439 struct catchtag c;
1436 struct handler h; 1440 struct handler h;
1437 1441
1438#if 0 /* We now handle interrupt_input_blocked properly. 1442 /* Since Fsignal will close off all calls to x_catch_errors,
1439 What we still do not handle is exiting a signal handler. */ 1443 we will get the wrong results if some are not closed now. */
1444 if (x_catching_errors ())
1440 abort (); 1445 abort ();
1441#endif
1442 1446
1443 c.tag = Qnil; 1447 c.tag = Qnil;
1444 c.val = Qnil; 1448 c.val = Qnil;
@@ -1481,6 +1485,11 @@ internal_condition_case_1 (bfun, arg, handlers, hfun)
1481 struct catchtag c; 1485 struct catchtag c;
1482 struct handler h; 1486 struct handler h;
1483 1487
1488 /* Since Fsignal will close off all calls to x_catch_errors,
1489 we will get the wrong results if some are not closed now. */
1490 if (x_catching_errors ())
1491 abort ();
1492
1484 c.tag = Qnil; 1493 c.tag = Qnil;
1485 c.val = Qnil; 1494 c.val = Qnil;
1486 c.backlist = backtrace_list; 1495 c.backlist = backtrace_list;
@@ -1525,6 +1534,11 @@ internal_condition_case_2 (bfun, nargs, args, handlers, hfun)
1525 struct catchtag c; 1534 struct catchtag c;
1526 struct handler h; 1535 struct handler h;
1527 1536
1537 /* Since Fsignal will close off all calls to x_catch_errors,
1538 we will get the wrong results if some are not closed now. */
1539 if (x_catching_errors ())
1540 abort ();
1541
1528 c.tag = Qnil; 1542 c.tag = Qnil;
1529 c.val = Qnil; 1543 c.val = Qnil;
1530 c.backlist = backtrace_list; 1544 c.backlist = backtrace_list;