Ethereal-users: Re: [Ethereal-users] How to terminate tethereal from a tcl progra m on Windows?
On Tue, May 28, 2002 at 05:46:32PM +0100, Alistair.McGlinchy@xxxxxxxxxxxxxxxxxxxxx wrote:
> This may not be the same problem as you, but a work colleague and I have
> been having continuing problems with Ctrl-Break and Ctrl-C handling and
> tethereal since version 0.9 came out.
I've just checked in a fix for the exception. (The problem is that the
handlers for Ctrl-Break and Ctrl-C run in a separate thread, but the
handlers are doing a "longjmp()", which is longjmping to a frame in the
main thread's stack, which is not legal.)
That fix should be in the next release.
> Ctrl-Break halts tethereal immediately without allowing it to flush its file
> buffers.
Another part of the fix should cause the handler to handle Ctrl-Break as
well as Ctrl-C (I'm using the native "catch a console signal" API rather
than the UNIX-wrapper "signal(SIGINT, ...)" call, so it catches a number
of termination signals).
> A search on
> google for 0xc0000029 shows that other Perl and Ruby based apps also seem to
> have this problem with Ctrl-C .
("Other" Perl and Ruby-based apps? Ethereal is neither Perl-based nor
Ruby-based.)
It may be that the Perl and Ruby interpreters are doing the same
"longjmp from a SIGINT handler" thing, which *is* legal in UNIX signal
handlers and is thus done in UNIX applications. Unfortunately, it
causes crashes in Windows.