Commit dd1ec041 authored by Paul Querna's avatar Paul Querna
Browse files

Reset the timers when in the child -- this prevents a fork bomb, as each child...

Reset the timers when in the child -- this prevents a fork bomb, as each child would spawn N more children of its own, as the scheduled timer would go off in the child and the parent.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@709655 13f79535-47bb-0310-9956-ffa450edef68
parent 0dd63724
Loading
Loading
Loading
Loading
+6 −0
Changes for server/mpm/simple/simple_run.c: 6 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -281,6 +281,12 @@ int simple_child_loop(simple_core_t * sc)
        return rv;
    }

    /* XXXXX: Hack. Reseting parts of the simple core needs to be more
     * thought out than this. 
     */
    APR_RING_INIT(&sc->timer_ring, simple_timer_t, link);
    APR_RING_INIT(&sc->dead_timer_ring, simple_timer_t, link);

    rv = simple_setup_workers(sc);
    if (rv) {
        ap_log_error(APLOG_MARK, APLOG_CRIT, rv, NULL,