From: Brian Havard Date: Thu, 10 Jan 2002 15:09:18 +0000 (+0000) Subject: Get OS/2 MPM working again after last scoreboard changes. X-Git-Tag: 2.0.31~230 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=5e35f192f33edc9b4eb1d33e478150e779bd7ed9;p=apache Get OS/2 MPM working again after last scoreboard changes. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@92808 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/server/mpm/mpmt_os2/mpmt_os2.c b/server/mpm/mpmt_os2/mpmt_os2.c index e20ecd146d..7cd31b5c0e 100644 --- a/server/mpm/mpmt_os2/mpmt_os2.c +++ b/server/mpm/mpmt_os2/mpmt_os2.c @@ -298,7 +298,7 @@ static char master_main() /* Allocate shared memory for scoreboard */ if (ap_scoreboard_image == NULL) { void *sb_mem; - rc = DosAllocSharedMem((PPVOID)&sbmem, ap_scoreboard_fname, + rc = DosAllocSharedMem(&sb_mem, ap_scoreboard_fname, ap_calc_scoreboard_size(), PAG_COMMIT|PAG_READ|PAG_WRITE); diff --git a/server/mpm/mpmt_os2/mpmt_os2_child.c b/server/mpm/mpmt_os2/mpmt_os2_child.c index 8ae9702a1b..6475fa599a 100644 --- a/server/mpm/mpmt_os2/mpmt_os2_child.c +++ b/server/mpm/mpmt_os2/mpmt_os2_child.c @@ -144,6 +144,7 @@ void ap_mpm_child_main(apr_pool_t *pconf) apr_pollfd_t *pollset; int num_listeners; TID server_maint_tid; + void *sb_mem; /* Stop Ctrl-C/Ctrl-Break signals going to child processes */ DosSetSignalExceptionFocus(0, &ulTimes); @@ -164,7 +165,7 @@ void ap_mpm_child_main(apr_pool_t *pconf) } /* Gain access to the scoreboard. */ - rc = DosGetNamedSharedMem((PPVOID)&ap_scoreboard_image, ap_scoreboard_fname, + rc = DosGetNamedSharedMem(&sb_mem, ap_scoreboard_fname, PAG_READ|PAG_WRITE); if (rc) { @@ -173,6 +174,9 @@ void ap_mpm_child_main(apr_pool_t *pconf) clean_child_exit(APEXIT_CHILDFATAL); } + ap_calc_scoreboard_size(); + ap_init_scoreboard(sb_mem); + /* Gain access to the accpet mutex */ rc = DosOpenMutexSem(NULL, &ap_mpm_accept_mutex);