Re: Signal handling issues with libcurl ?
Date: Wed, 5 Nov 2008 11:49:06 -0800
On Wed, Nov 05, 2008 at 06:34:07AM -0800, Hassan Shaik wrote:
> - Before invoking native code (which internally calls libcurl API), this
> signal handler works fine and JVM does not crash when SIGPIPE signal is
> - But, once the native code is called, the Java signal handler is not
> working and not catching SIGPIPE any more. JVM just crashes. Looks like,
> it is set to SIG_DFL.
> Is libcurl modifies the signal handling behavior and does not restore
> back to the original signal handling behavior of the application?
libcurl does modify the SIGPIPE handler at the start of a transfer, but
restores it back to the old handler once the transfer is complete.
> I read through about CURLOPT_NOSIGNAL option. Does setting this flag to
> 1 help anyway?
If you set this flag then libcurl won't change any signal handler. But
that has other side effects that may or may not affect your program.
-- http://www.MoveAnnouncer.com The web change of address service Let webmasters know that your web site has movedReceived on 2008-11-05