JDK-4785154 : VM uselessly traps SIGCHLD on Linux (cleanup)
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 1.3.1_09,1.4.2,1.4.2_05
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • OS: linux,linux_redhat_4.0
  • CPU: generic,x86,itanium
  • Submitted: 2002-11-26
  • Updated: 2012-10-08
  • Resolved: 2003-06-21
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
1.4.2_11Fixed
Related Reports
Duplicate :  
Duplicate :  
Relates :  
Description
On both i486 and ia64 Linux the runtime code traps SIGCHLD and handles it as
follows:

  /* from os_linux_i486.cpp; ia64 code is identical */
  if (sig == SIGCHLD) {
    // cleanup zombie pid for child thread
    ::waitpid(-1, 0, WNOHANG);
    return 1;
  }

This test, and the corresponding setup of the signal handler to catch SIGCHLD,
serve no purpose and should be removed.  (See 4763362 for details.)

-- ###@###.### 2002/11/26

Comments
SUGGESTED FIX Yes, http://raq.sfbay.sun.com/~huanghui/webrev/20030410/src/os_cpu/linux_i486/vm/os_linux_i486.cpp.diff.html *** 120,135 *** is related to the fix and also http://raq.sfbay.sun.com/~huanghui/webrev/20030410/src/os/linux/vm/os_linux.cpp.diff.html *** 1636,1648 ***
29-08-2005

CONVERTED DATA BugTraq+ Release Management Values COMMIT TO FIX: tiger FIXED IN: tiger INTEGRATED IN: tiger-b05
14-06-2004

EVALUATION The problem has been fixed in J2SE workspace by bug 4763362. The only thing left is a cleanup to remove the SIGCHLD code from JVM_handle_linux_signal. It is harmless after 4763362, will fix in Tiger. ###@###.### 2003-01-15 Fixed by removing SIGCHLD handling from JVM. ###@###.### 2003-04-12 ----------------------------- The fix for 4763362 is not complete, it only solves the problem in Java code, same problem still exists in JNI code until this bug is fixed in 1.5. There has been two bugs recently filed against JVM (4945203 and 4954748). This is no longer a simple clean-up as we thought before. CTE, please consider backporting the fix from 1.5. Returning incorrect return value after a fork() or system() call is very bad. ###@###.### 2003-11-17
17-11-2003