Date: Thu, 28 Jan 1999 09:21:27 -0700 From: Nate Williams <nate@mt.sri.com> To: hashi@csl.rdc.toshiba.co.jp (Mikio Hashimoto) Cc: freebsd-java@FreeBSD.ORG Subject: Re: signal handling in FreeBSD Java Message-ID: <199901281621.JAA29588@mt.sri.com> In-Reply-To: <199901280818.RAA18097@mailhost.csl.rdc.toshiba.co.jp> References: <199901280818.RAA18097@mailhost.csl.rdc.toshiba.co.jp>
next in thread | previous in thread | raw e-mail | index | archive | help
> I'm developing a program that uses JNI and asynchronous IO. The > program handles asynchronous input from a special socket interface > through JNI, as shown in figure below. > On arriving an asynchronous input, a signal SIGUSR1 is issued from > the socket interface to the java process, then a preregistered signal > handler of the java process is called. I'm not sure if this is documented, but SIGUSR1 is not allowed in JNI programs as it's the signal used internally in the VM to signal 'thread interrupt'. > User Java Library(with awt) > ------------------------------------------- > freebsd-jdk 1.1.7 > > Java VM +-------------------------------- > | Native Method (written in C ) > -----------+--------------------------------- > IO,etc | special socket I/F for IEEE 1394 > Free BSD kernel > > This program well worked for simple test program without awt widget > library. But once GUI program with awt applied to the program, the > java process frequently crashes or hangs up. Sometimes following > messages can be seen. > > 1) X11TransSocketINETConnect: Can't connect errno=4 > 2) Warning: select failed > > I guess the message 1) tells that some signals(probably my socket > signal) disrupted socket operation in X windows system. The error > number four corresponds to the EINTR error. Is it right? See above. Try using SIGUSR2 and see if things work better. Nate To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199901281621.JAA29588>