httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marc Slemko <m...@hyperreal.org>
Subject cvs commit: apache/src mod_cgi.c
Date Tue, 08 Jul 1997 04:08:58 GMT
marc        97/07/07 21:08:57

  Modified:    src       mod_cgi.c
  Log:
  Properly use HUGE_STRING_LEN instead of MAX_STRING_LEN for two calls
  and remove bogus -1 in size for bgets().
  
  Submitted by:	Stanley Gambarin, Marc Slemko
  
  Revision  Changes    Path
  1.44      +9 -9      apache/src/mod_cgi.c
  
  Index: mod_cgi.c
  ===================================================================
  RCS file: /export/home/cvs/apache/src/mod_cgi.c,v
  retrieving revision 1.43
  retrieving revision 1.44
  diff -C3 -r1.43 -r1.44
  *** mod_cgi.c	1997/07/06 05:37:20	1.43
  --- mod_cgi.c	1997/07/08 04:08:56	1.44
  ***************
  *** 197,205 ****
    	((f = pfopen(r->pool, server_root_relative(r->pool, conf->logname),
    		     "a")) == NULL)) {
          /* Soak up script output */
  !       while (bgets(argsbuffer, MAX_STRING_LEN-1, script_in))
    	continue;
  !       while (bgets(argsbuffer, MAX_STRING_LEN-1, script_err))
    	continue;
          return ret;
        }
  --- 197,205 ----
    	((f = pfopen(r->pool, server_root_relative(r->pool, conf->logname),
    		     "a")) == NULL)) {
          /* Soak up script output */
  !       while (bgets(argsbuffer, HUGE_STRING_LEN, script_in))
    	continue;
  !       while (bgets(argsbuffer, HUGE_STRING_LEN, script_err))
    	continue;
          return ret;
        }
  ***************
  *** 233,253 ****
          fprintf(f, "%s\n", sbuf);
    
        *argsbuffer = '\0';
  !     bgets(argsbuffer, HUGE_STRING_LEN-1, script_in);
        if (*argsbuffer) {
          fputs("%stdout\n", f);
          fputs(argsbuffer, f);
  !       while (bgets(argsbuffer, HUGE_STRING_LEN-1, script_in))
    	fputs(argsbuffer, f);
          fputs("\n", f);
        }
    
        *argsbuffer = '\0';
  !     bgets(argsbuffer, HUGE_STRING_LEN-1, script_err);
        if (*argsbuffer) {
          fputs("%stderr\n", f);
          fputs(argsbuffer, f);
  !       while (bgets(argsbuffer, HUGE_STRING_LEN-1, script_err))
    	fputs(argsbuffer, f);
          fputs("\n", f);
        }
  --- 233,253 ----
          fprintf(f, "%s\n", sbuf);
    
        *argsbuffer = '\0';
  !     bgets(argsbuffer, HUGE_STRING_LEN, script_in);
        if (*argsbuffer) {
          fputs("%stdout\n", f);
          fputs(argsbuffer, f);
  !       while (bgets(argsbuffer, HUGE_STRING_LEN, script_in))
    	fputs(argsbuffer, f);
          fputs("\n", f);
        }
    
        *argsbuffer = '\0';
  !     bgets(argsbuffer, HUGE_STRING_LEN, script_err);
        if (*argsbuffer) {
          fputs("%stderr\n", f);
          fputs(argsbuffer, f);
  !       while (bgets(argsbuffer, HUGE_STRING_LEN, script_err))
    	fputs(argsbuffer, f);
          fputs("\n", f);
        }
  ***************
  *** 492,500 ****
    	  
    	    /* Soak up all the script output */
    	    hard_timeout ("read from script", r);
  ! 	    while (bgets(argsbuffer, HUGE_STRING_LEN-1, script_in))
    	        continue;
  ! 	    while (bgets(argsbuffer, HUGE_STRING_LEN-1, script_err))
    	        continue;
    	    kill_timeout (r);
    
  --- 492,500 ----
    	  
    	    /* Soak up all the script output */
    	    hard_timeout ("read from script", r);
  ! 	    while (bgets(argsbuffer, HUGE_STRING_LEN, script_in))
    	        continue;
  ! 	    while (bgets(argsbuffer, HUGE_STRING_LEN, script_err))
    	        continue;
    	    kill_timeout (r);
    
  ***************
  *** 526,532 ****
    	    send_fb(script_in, r);
    
    	soft_timeout("soaking script stderr", r);
  ! 	while(bgets(argsbuffer, HUGE_STRING_LEN-1, script_err))
    	      continue;
    	kill_timeout(r);
    	     
  --- 526,532 ----
    	    send_fb(script_in, r);
    
    	soft_timeout("soaking script stderr", r);
  ! 	while(bgets(argsbuffer, HUGE_STRING_LEN, script_err))
    	      continue;
    	kill_timeout(r);
    	     
  
  
  

Mime
View raw message