DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=8176>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=8176 logic error in reclaim_child_processes function called during shutdown Summary: logic error in reclaim_child_processes function called during shutdown Product: Apache httpd-1.3 Version: 1.3.23 Platform: All OS/Version: Linux Status: NEW Severity: Normal Priority: Other Component: core AssignedTo: bugs@httpd.apache.org ReportedBy: [EMAIL PROTECTED] This function is called at shutdown to kill off all of the children processes that were spawned during startup and runtime. The bug is around line 2742 where ap_select is called. It seems that the intention was to use the select command as a precision sleep mechanism. As the comment indicates, some time needs to be allowed for children processes to do their termination stuff. The problem was that ap_select was returning prematurely as a result of a signal interupt (errno = EINTR), and therefore was never really sleeping for the expected amount of time. This didn't allow enough time for my children process to clean themselves up and resulted in various resource leaks. I changed the line from: ap_select(0, NULL, NULL, NULL, &tv); to: while(ap_select(0, NULL, NULL, NULL, &tv) == -1) {} And while I am not saying that this code is the best way to do this, it did work, allowing my children to die a natural death.