View | Details | Raw Unified | Return to bug 39275
Collapse All | Expand All

(-)worker.c.orig (+9 lines)
Lines 1001-1006 Link Here
1001
        if (!listener_started && threads_created) {
1001
        if (!listener_started && threads_created) {
1002
            create_listener_thread(ts);
1002
            create_listener_thread(ts);
1003
            listener_started = 1;
1003
            listener_started = 1;
1004
1005
            ap_scoreboard_image->parent[child_num_arg].status = SERVER_READY;
1004
        }
1006
        }
1005
        if (start_thread_may_exit || threads_created == ap_threads_per_child) {
1007
        if (start_thread_may_exit || threads_created == ap_threads_per_child) {
1006
            break;
1008
            break;
Lines 1279-1284 Link Here
1279
    if (one_process) {
1281
    if (one_process) {
1280
        set_signals();
1282
        set_signals();
1281
        ap_scoreboard_image->parent[slot].pid = getpid();
1283
        ap_scoreboard_image->parent[slot].pid = getpid();
1284
        ap_scoreboard_image->parent[slot].status = SERVER_STARTING;
1282
        child_main(slot);
1285
        child_main(slot);
1283
    }
1286
    }
1284
1287
Lines 1336-1341 Link Here
1336
    }
1339
    }
1337
    ap_scoreboard_image->parent[slot].quiescing = 0;
1340
    ap_scoreboard_image->parent[slot].quiescing = 0;
1338
    ap_scoreboard_image->parent[slot].pid = pid;
1341
    ap_scoreboard_image->parent[slot].pid = pid;
1342
    ap_scoreboard_image->parent[slot].status = SERVER_STARTING;
1339
    return 0;
1343
    return 0;
1340
}
1344
}
1341
1345
Lines 1399-1404 Link Here
1399
        if (i >= ap_max_daemons_limit && totally_free_length == idle_spawn_rate)
1403
        if (i >= ap_max_daemons_limit && totally_free_length == idle_spawn_rate)
1400
            break;
1404
            break;
1401
        ps = &ap_scoreboard_image->parent[i];
1405
        ps = &ap_scoreboard_image->parent[i];
1406
        if (ps->pid != 0 && ps->status == SERVER_STARTING) {
1407
            idle_thread_count += ap_threads_per_child;
1408
            continue;
1409
        }
1402
        for (j = 0; j < ap_threads_per_child; j++) {
1410
        for (j = 0; j < ap_threads_per_child; j++) {
1403
            ws = &ap_scoreboard_image->servers[i][j];
1411
            ws = &ap_scoreboard_image->servers[i][j];
1404
            status = ws->status;
1412
            status = ws->status;
Lines 1567-1572 Link Here
1567
1575
1568
                ap_scoreboard_image->parent[child_slot].pid = 0;
1576
                ap_scoreboard_image->parent[child_slot].pid = 0;
1569
                ap_scoreboard_image->parent[child_slot].quiescing = 0;
1577
                ap_scoreboard_image->parent[child_slot].quiescing = 0;
1578
                ap_scoreboard_image->parent[child_slot].status = 0;
1570
                if (processed_status == APEXIT_CHILDSICK) {
1579
                if (processed_status == APEXIT_CHILDSICK) {
1571
                    /* resource shortage, minimize the fork rate */
1580
                    /* resource shortage, minimize the fork rate */
1572
                    idle_spawn_rate = 1;
1581
                    idle_spawn_rate = 1;

Return to bug 39275