Lines Matching refs:g_prefork_server
2436 static lsapi_prefork_server * g_prefork_server = NULL; variable
2441 if ( g_prefork_server ) in LSAPI_Init_Prefork_Server()
2449 g_prefork_server = (lsapi_prefork_server *)malloc( sizeof( lsapi_prefork_server ) ); in LSAPI_Init_Prefork_Server()
2450 if ( !g_prefork_server ) in LSAPI_Init_Prefork_Server()
2452 memset( g_prefork_server, 0, sizeof( lsapi_prefork_server ) ); in LSAPI_Init_Prefork_Server()
2460 g_prefork_server->m_iAvoidFork = avoidFork; in LSAPI_Init_Prefork_Server()
2461 g_prefork_server->m_iMaxChildren = max_children; in LSAPI_Init_Prefork_Server()
2463 g_prefork_server->m_iExtraChildren = ( avoidFork ) ? 0 : (max_children / 3) ; in LSAPI_Init_Prefork_Server()
2464 g_prefork_server->m_iMaxIdleChildren = ( avoidFork ) ? (max_children + 1) : (max_children / 3); in LSAPI_Init_Prefork_Server()
2465 if ( g_prefork_server->m_iMaxIdleChildren == 0 ) in LSAPI_Init_Prefork_Server()
2466 g_prefork_server->m_iMaxIdleChildren = 1; in LSAPI_Init_Prefork_Server()
2467 g_prefork_server->m_iChildrenMaxIdleTime = 300; in LSAPI_Init_Prefork_Server()
2468 g_prefork_server->m_iMaxReqProcessTime = 3600; in LSAPI_Init_Prefork_Server()
2474 if( g_prefork_server ) in LSAPI_Set_Server_fd()
2475 g_prefork_server->m_fd = fd; in LSAPI_Set_Server_fd()
2520 lsapi_child_status * pStatus = g_prefork_server->m_pChildrenStatus; in find_child_status()
2521 lsapi_child_status * pEnd = g_prefork_server->m_pChildrenStatusEnd; in find_child_status()
2526 if ( pStatus + 1 > g_prefork_server->m_pChildrenStatusCur ) in find_child_status()
2527 g_prefork_server->m_pChildrenStatusCur = pStatus + 1; in find_child_status()
2563 --g_prefork_server->m_iCurChildren; in lsapi_sigchild()
2567 while(( g_prefork_server->m_pChildrenStatusCur > g_prefork_server->m_pChildrenStatus ) in lsapi_sigchild()
2568 &&( g_prefork_server->m_pChildrenStatusCur[-1].m_pid == 0 )) in lsapi_sigchild()
2569 --g_prefork_server->m_pChildrenStatusCur; in lsapi_sigchild()
2578 …size = (g_prefork_server->m_iMaxChildren + g_prefork_server->m_iExtraChildren ) * sizeof( lsapi_ch… in lsapi_init_children_status()
2588 g_prefork_server->m_pChildrenStatus = (lsapi_child_status *)pBuf; in lsapi_init_children_status()
2589 g_prefork_server->m_pChildrenStatusCur = (lsapi_child_status *)pBuf; in lsapi_init_children_status()
2590 …g_prefork_server->m_pChildrenStatusEnd = (lsapi_child_status *)pBuf + size / sizeof( lsapi_child_s… in lsapi_init_children_status()
2619 lsapi_child_status * pStatus = g_prefork_server->m_pChildrenStatus; in lsapi_check_child_status()
2620 lsapi_child_status * pEnd = g_prefork_server->m_pChildrenStatusCur; in lsapi_check_child_status()
2630 if (( g_prefork_server->m_iCurChildren - dying > g_prefork_server->m_iMaxChildren)|| in lsapi_check_child_status()
2631 ( idle > g_prefork_server->m_iMaxIdleChildren )) in lsapi_check_child_status()
2650 g_prefork_server->m_iMaxReqProcessTime ) in lsapi_check_child_status()
2682 if ( abs( g_prefork_server->m_iCurChildren - count ) > 1 ) in lsapi_check_child_status()
2685 g_prefork_server->m_iCurChildren, count, idle, dying ); in lsapi_check_child_status()
2694 g_prefork_server->m_iMaxReqProcessTime = 10; in lsapi_all_children_must_die()
2695 g_prefork_server->m_iMaxIdleChildren = -1; in lsapi_all_children_must_die()
2698 while( g_prefork_server->m_iCurChildren && (sec < maxWait) ) in lsapi_all_children_must_die()
2704 if ( g_prefork_server->m_iCurChildren != 0 ) in lsapi_all_children_must_die()
2830 g_prefork_server = NULL; in lsapi_prefork_server_accept()
2905 if ( g_prefork_server ) in LSAPI_Prefork_Accept_r()
2907 if ( g_prefork_server->m_fd != -1 ) in LSAPI_Prefork_Accept_r()
2908 if ( lsapi_prefork_server_accept( g_prefork_server, pReq ) == -1 ) in LSAPI_Prefork_Accept_r()
3025 if ( g_prefork_server ) in LSAPI_Set_Max_Children()
3026 g_prefork_server->m_iMaxChildren = maxChildren; in LSAPI_Set_Max_Children()
3031 if (( g_prefork_server )&&( extraChildren >= 0 )) in LSAPI_Set_Extra_Children()
3032 g_prefork_server->m_iExtraChildren = extraChildren; in LSAPI_Set_Extra_Children()
3037 if (( g_prefork_server )&&( secs > 0 )) in LSAPI_Set_Max_Process_Time()
3038 g_prefork_server->m_iMaxReqProcessTime = secs; in LSAPI_Set_Max_Process_Time()
3044 if (( g_prefork_server )&&( maxIdleChld > 0 )) in LSAPI_Set_Max_Idle_Children()
3045 g_prefork_server->m_iMaxIdleChildren = maxIdleChld; in LSAPI_Set_Max_Idle_Children()
3050 if ( g_prefork_server ) in LSAPI_Set_Server_Max_Idle_Secs()
3051 g_prefork_server->m_iServerMaxIdle = serverMaxIdle; in LSAPI_Set_Server_Max_Idle_Secs()
3123 if ( g_prefork_server ) in lsapi_initSuEXEC()
3125 if ( g_prefork_server->m_iMaxChildren < 100 ) in lsapi_initSuEXEC()
3126 g_prefork_server->m_iMaxChildren = 100; in lsapi_initSuEXEC()
3127 if ( g_prefork_server->m_iExtraChildren < 1000 ) in lsapi_initSuEXEC()
3128 g_prefork_server->m_iExtraChildren = 1000; in lsapi_initSuEXEC()