changeset 9059:eabdfcc977f1

make unwind_protect handle also keyboard interrupts
author Jaroslav Hajek <highegg@gmail.com>
date Sun, 29 Mar 2009 21:30:17 +0200
parents 2da105bf2507
children de7cef39f505
files src/ChangeLog src/pt-eval.cc
diffstat 2 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,8 @@
+2009-03-29  Jaroslav Hajek  <highegg@gmail.com>
+
+	* pt-eval.cc (do_unwind_protect_cleanup_code): Protect also
+	octave_interrupt_state.
+
 2009-03-29  Jaroslav Hajek  <highegg@gmail.com>
 
 	* DLD-FUNCTIONS/cellfun.cc (Fcellslices): Index n-d arrays along the
--- a/src/pt-eval.cc
+++ b/src/pt-eval.cc
@@ -917,6 +917,9 @@
   unwind_protect_int (error_state);
   error_state = 0;
 
+  unwind_protect_int (octave_interrupt_state);
+  octave_interrupt_state = 0;
+
   // Similarly, if we have seen a return or break statement, allow all
   // the cleanup code to run before returning or handling the break.
   // We don't have to worry about continue statements because they can