|Subject:||Re: Win32 CTRL-C handling (Was: interrupt handing and the GUI (bug #37672))|
|Date:||Tue, 19 Nov 2013 11:38:36 -0500|
On 11/19/2013 08:01 AM, Michael Goffioul wrote:I see. Yes, it is the same problem in the GUI. But it works with the CLI version on Linux, but not on my Windows build.
That's because when using the GUI, no signal is really generated at the
OS-level. The signal is raised in the octave process; bu raising a
signal in Win32 simply means executing its handler. So SIGINT is not
seen by the child processes. I tried to use GenerateConsoleCtrlEvent,
but it exited octave instead of executing the ctrl-c handler. There's
something I'm missing there, this requires further investigation.
But don't you have the same issue in Linux? Or does pthread_kill
propagates to child processes?
On Windows with your patch for interrupt handling, interrupts in the GUI seem to be working reasonably well except for the problem with the system function. When I run octave-cli in an MSYS shell, Ctrl-C at teh command prompt (while readline is waiting for input) doesn't have nay effect
and Ctrl-C at other times (during a function call or loop execution) exits the Octave process. If I use octave --no-gui-libs, then strange things happen after Ctrl-C causes Octave to exit. I then see alternating MSYS shell prompts and Octave prompts and neither works properly.
|[Prev in Thread]||Current Thread||[Next in Thread]|