changeset 29294:6867e1e12815

respond to interrupt signals when idle in the server loop * pt-eval.cc (tree_evaluator::server_loop, debugger::server_loop): Call octave_quit just before executing commands.
author John W. Eaton <jwe@octave.org>
date Thu, 14 Jan 2021 01:11:44 -0500
parents 8784f20b9b8c
children b73ddb964093
files libinterp/parse-tree/pt-eval.cc
diffstat 1 files changed, 10 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libinterp/parse-tree/pt-eval.cc	Thu Jan 14 01:08:40 2021 -0500
+++ b/libinterp/parse-tree/pt-eval.cc	Thu Jan 14 01:11:44 2021 -0500
@@ -168,6 +168,11 @@
 
         try
           {
+            // FIXME: Should we call octave_quit in the octave::sleep
+            // and/or command_editor::run_event_hooks functions?
+
+            octave_quit ();
+
             // FIXME: Running the event queue should be decoupled from
             // the command_editor.
 
@@ -764,6 +769,11 @@
       {
         try
           {
+            // FIXME: Should we call octave_quit in the octave::sleep
+            // and/or command_editor::run_event_hooks functions?
+
+            octave_quit ();
+
             // FIXME: Running the event queue should be decoupled from
             // the command_editor.  We should also use a condition
             // variable to manage the execution of entries in the queue