You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by bn...@apache.org on 2002/01/14 23:36:03 UTC

cvs commit: httpd-2.0/server scoreboard.c

bnicholes    02/01/14 14:36:03

  Modified:    server   scoreboard.c
  Log:
  Added APR_HAS_SHARED_MEMORY to a section of code where it was
  missing, for those of us that don't have shared memory support.
  
  Revision  Changes    Path
  1.46      +6 -1      httpd-2.0/server/scoreboard.c
  
  Index: scoreboard.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/server/scoreboard.c,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -r1.45 -r1.46
  --- scoreboard.c	10 Jan 2002 00:27:58 -0000	1.45
  +++ scoreboard.c	14 Jan 2002 22:36:03 -0000	1.46
  @@ -230,12 +230,15 @@
   void ap_create_scoreboard(apr_pool_t *p, ap_scoreboard_e sb_type)
   {
       int running_gen = 0;
  +#if APR_HAS_SHARED_MEMORY
       apr_status_t rv;
  +#endif
   
       if (ap_scoreboard_image)
   	running_gen = ap_scoreboard_image->global->running_generation;
       if (ap_scoreboard_image == NULL) {
           ap_calc_scoreboard_size();
  +#if APR_HAS_SHARED_MEMORY
           if (sb_type == SB_SHARED) {
               void *sb_shared;
               rv = open_scoreboard(p);
  @@ -253,7 +256,9 @@
               }
               ap_init_scoreboard(sb_shared);
           }
  -        else {
  +        else 
  +#endif
  +        {
               /* A simple malloc will suffice */
               void *sb_mem = calloc(1, scoreboard_size);
               if (sb_mem == NULL) {