httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jim Jagielski <...@hyperreal.com>
Subject cvs commit: apache/src http_main.c
Date Fri, 06 Sep 1996 18:36:11 GMT
jim         96/09/06 11:36:11

  Modified:    src       http_main.c
  Log:
  Description: Make sure that the scoreboard array and file are synced
               as needed.
  
  Revision  Changes    Path
  1.64      +7 -4      apache/src/http_main.c
  
  Index: http_main.c
  ===================================================================
  RCS file: /export/home/cvs/apache/src/http_main.c,v
  retrieving revision 1.63
  retrieving revision 1.64
  diff -C3 -r1.63 -r1.64
  *** http_main.c	1996/08/23 18:19:11	1.63
  --- http_main.c	1996/09/06 18:36:08	1.64
  ***************
  *** 50,56 ****
     *
     */
    
  ! /* $Id: http_main.c,v 1.63 1996/08/23 18:19:11 jim Exp $ */
    
    /*
     * httpd.c: simple http daemon for answering WWW file requests
  --- 50,56 ----
     *
     */
    
  ! /* $Id: http_main.c,v 1.64 1996/09/06 18:36:08 jim Exp $ */
    
    /*
     * httpd.c: simple http daemon for answering WWW file requests
  ***************
  *** 753,763 ****
    int update_child_status (int child_num, int status, request_rec *r)
    {
        int old_status;
  !     short_score new_score_rec=scoreboard_image->servers[child_num];
    
        if (child_num < 0)
    	return -1;
        
        new_score_rec.pid = getpid();
        old_status = new_score_rec.status;
        new_score_rec.status = status;
  --- 753,765 ----
    int update_child_status (int child_num, int status, request_rec *r)
    {
        int old_status;
  !     short_score new_score_rec;
    
        if (child_num < 0)
    	return -1;
        
  +     sync_scoreboard_image();
  +     new_score_rec = scoreboard_image->servers[child_num];
        new_score_rec.pid = getpid();
        old_status = new_score_rec.status;
        new_score_rec.status = status;
  ***************
  *** 852,859 ****
    {
        long int bs=0;
        time_t now;
  !     short_score new_score_rec=scoreboard_image->servers[child_num];
    
        if (r->sent_bodyct)
            bgetopt(r->connection->client, BO_BYTECT, &bs);
    
  --- 854,863 ----
    {
        long int bs=0;
        time_t now;
  !     short_score new_score_rec;
    
  +     sync_scoreboard_image();
  +     new_score_rec = scoreboard_image->servers[child_num];
        if (r->sent_bodyct)
            bgetopt(r->connection->client, BO_BYTECT, &bs);
    
  ***************
  *** 959,965 ****
    	   && waitpid(scoreboard_image->servers[n].pid,&status,WNOHANG) == -1
    	   && errno == ECHILD)
    	    {
  - 	    sync_scoreboard_image();
    	    update_child_status(n,SERVER_DEAD,NULL);
    	    }
        }
  --- 963,968 ----
  
  
  

Mime
View raw message