httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r..@locus.apache.org
Subject cvs commit: apache-2.0/src/support ab.c
Date Fri, 10 Nov 2000 19:01:34 GMT
rbb         00/11/10 11:01:33

  Modified:    src/ap   ap_buckets.c ap_cache.c
               src/include buff.h
               src/lib/apr/file_io/unix fullrw.c
               src/main buff.c
               src/modules/mpm/dexter dexter.c
               src/modules/mpm/mpmt_pthread mpmt_pthread.c
               src/modules/mpm/perchild perchild.c
               src/modules/standard mod_autoindex.c mod_cgid.c
                        mod_include.c mod_log_config.c
               src/support ab.c
  Log:
  Fix a lot of the fallback from the apr_ssize_t to apr_size_t change
  Submitted by:	Victor J. Orlikowski <v.j.orlikowski@gte.net>
  
  Revision  Changes    Path
  1.31      +1 -1      apache-2.0/src/ap/ap_buckets.c
  
  Index: ap_buckets.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/ap/ap_buckets.c,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -r1.30 -r1.31
  --- ap_buckets.c	2000/11/07 20:21:05	1.30
  +++ ap_buckets.c	2000/11/10 19:01:29	1.31
  @@ -142,7 +142,7 @@
       ap_bucket *r;
       const char *x;
       int j, k;
  -    apr_ssize_t i;
  +    apr_size_t i;
   
       for (k = 0;;) {
           x = va_arg(va, const char *);
  
  
  
  1.10      +1 -1      apache-2.0/src/ap/ap_cache.c
  
  Index: ap_cache.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/ap/ap_cache.c,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- ap_cache.c	2000/09/10 20:45:15	1.9
  +++ ap_cache.c	2000/11/10 19:01:30	1.10
  @@ -187,7 +187,7 @@
       apr_file_t *place;
       char buffer[HUGE_STRING_LEN];
       apr_status_t ret = APR_SUCCESS;
  -    apr_ssize_t nbytes, i, o;
  +    apr_size_t nbytes, i, o;
       
       if((ret = ap_cache_el_data(el, &place)) != APR_SUCCESS) return ret;
       nbytes = HUGE_STRING_LEN;
  
  
  
  1.38      +3 -3      apache-2.0/src/include/buff.h
  
  Index: buff.h
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/include/buff.h,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -r1.37 -r1.38
  --- buff.h	2000/10/16 06:04:33	1.37
  +++ buff.h	2000/11/10 19:01:30	1.38
  @@ -150,7 +150,7 @@
                                      on an unbuffered stream, shouldn't change
                                      the saved error from I/O */
       unsigned char *inptr;	/* pointer to next location to read */
  -    apr_ssize_t incnt;		/* number of bytes left to read from input buffer;
  +    apr_size_t incnt;		/* number of bytes left to read from input buffer;
   				 * always 0 if had a read error  */
       int outchunk;               /* location of chunk header when chunking */
       int outcnt;			/* number of byte put in output buffer */
  @@ -243,7 +243,7 @@
    * bytes to have been read even if an error (or APR_EOF) is returned.
    */
   AP_DECLARE(apr_status_t) ap_bread_core(BUFF *fb, void *buf, apr_size_t nbyte,
  -                                 apr_ssize_t *bytes_read);
  +                                 apr_size_t *bytes_read);
   AP_DECLARE(int) ap_bgets(char *s, int n, BUFF *fb);
   AP_DECLARE(int) ap_blookc(BUFF *fb);
   /* write bytes from the specified buffer.
  @@ -251,7 +251,7 @@
    * for both an error to be returned, and bytes to have been written.
    */
   AP_DECLARE(apr_status_t) ap_bwrite_core(BUFF *fb, const void *buf, apr_size_t nbyte,
  -                                  apr_ssize_t *bytes_written);
  +                                  apr_size_t *bytes_written);
   #ifdef APACHE_XLATE
   #define ap_bwrite(fb,buf,nbyte,bytes_written) \
   (fb)->b_write_ops.bwrite(fb,buf,nbyte,bytes_written)
  
  
  
  1.4       +2 -2      apache-2.0/src/lib/apr/file_io/unix/fullrw.c
  
  Index: fullrw.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/lib/apr/file_io/unix/fullrw.c,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- fullrw.c	2000/08/02 05:25:51	1.3
  +++ fullrw.c	2000/11/10 19:01:30	1.4
  @@ -62,7 +62,7 @@
       apr_size_t total_read = 0;
   
       do {
  -	apr_ssize_t amt = (apr_ssize_t)nbytes;
  +	apr_size_t amt = nbytes;
   
   	status = apr_read(thefile, buf, &amt);
   	buf = (char *)buf + amt;
  @@ -83,7 +83,7 @@
       apr_size_t total_written = 0;
   
       do {
  -	apr_ssize_t amt = (apr_ssize_t)nbytes;
  +	apr_size_t amt = nbytes;
   
   	status = apr_write(thefile, buf, &amt);
   	buf = (char *)buf + amt;
  
  
  
  1.69      +17 -17    apache-2.0/src/main/buff.c
  
  Index: buff.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/main/buff.c,v
  retrieving revision 1.68
  retrieving revision 1.69
  diff -u -r1.68 -r1.69
  --- buff.c	2000/11/09 02:35:11	1.68
  +++ buff.c	2000/11/10 19:01:31	1.69
  @@ -353,7 +353,7 @@
   
   /* read without blocking, if EAGAIN, then flush */
   static apr_status_t saferead(BUFF *fb, void *buf, apr_size_t nbyte,
  -			apr_ssize_t *bytes_read)
  +			apr_size_t *bytes_read)
   {
       int rv;
       const int zero = 0;
  @@ -401,7 +401,7 @@
   
   /* a wrapper around apr_recv which checks for errors and EOFs */
   static apr_status_t read_with_errors(BUFF *fb, void *buf, apr_size_t nbyte,
  -                                    apr_ssize_t *bytes_read)
  +                                    apr_size_t *bytes_read)
   {
       apr_status_t rv = APR_EINIT;
    
  @@ -459,10 +459,10 @@
    * If fewer than nbyte bytes are currently available, then return those.
    */
   AP_DECLARE(apr_status_t) ap_bread_core(BUFF *fb, void *buf, apr_size_t nbyte,
  -                                      apr_ssize_t *bytes_read)
  +                                      apr_size_t *bytes_read)
   {
       int nrd;
  -    apr_ssize_t i;
  +    apr_size_t i;
       apr_status_t rv;
   
       if (fb->flags & B_RDERR) {
  @@ -559,7 +559,7 @@
   AP_DECLARE(int) ap_bgets(char *buff, int n, BUFF *fb)
   {
       int ch, ct;
  -    apr_ssize_t i;
  +    apr_size_t i;
       apr_status_t rv;
   
   /* Can't do bgets on an unbuffered stream */
  @@ -653,7 +653,7 @@
   AP_DECLARE(int) ap_bflsbuf(int c, BUFF *fb)
   {
       char ss[1];
  -    apr_ssize_t bytes_written;
  +    apr_size_t bytes_written;
       apr_status_t rv;
   
       ss[0] = c;
  @@ -671,7 +671,7 @@
   AP_DECLARE(int) ap_bfilbuf(BUFF *fb)
   {
       apr_status_t rv;
  -    apr_ssize_t i;
  +    apr_size_t i;
       char buf[1];
   
       rv = ap_bread(fb, buf, 1, &i);
  @@ -687,7 +687,7 @@
    * bytes_sent.
    */
   static apr_status_t writev_with_errors(BUFF *fb, const struct iovec *vec,
  -                                      int nvec, apr_ssize_t *bytes_written)
  +                                      int nvec, apr_size_t *bytes_written)
   {
       apr_status_t rv;
       rv = apr_sendv(fb->bsock, vec, nvec, bytes_written);
  @@ -704,11 +704,11 @@
   
   
   static apr_status_t writev_it_all(BUFF *fb, struct iovec *vec, int nvec,
  -                                 apr_ssize_t *bytes_written)
  +                                 apr_size_t *bytes_written)
   {
       int i;
       apr_status_t rv;
  -    apr_ssize_t n;
  +    apr_size_t n;
   
       i = 0;
       *bytes_written = 0;
  @@ -745,7 +745,7 @@
      doesn't include any bytes potentially written from fb->outbase.
   */
   static apr_status_t large_write(BUFF *fb, const char *buf, apr_size_t nbyte,
  -                               apr_ssize_t *bytes_written)
  +                               apr_size_t *bytes_written)
   {
       struct iovec vec[2];
       int nvec;
  @@ -810,7 +810,7 @@
       -djg
   */
   static apr_status_t large_write_chunk(BUFF *fb, const char *buf, apr_size_t nbyte,
  -                                     apr_ssize_t *bytes_written)
  +                                     apr_size_t *bytes_written)
   {
       return large_write(fb, buf, nbyte, bytes_written);
   }
  @@ -819,7 +819,7 @@
    * bytes_sent.
    */
   static apr_status_t write_with_errors(BUFF *fb, const void *buf, apr_size_t nbyte,
  -                                     apr_ssize_t *bytes_written)
  +                                     apr_size_t *bytes_written)
   {
       apr_status_t rv;
   
  @@ -840,7 +840,7 @@
   static apr_status_t bflush_core(BUFF *fb, apr_ssize_t *bytes_written)
   {
       apr_status_t rv;
  -    apr_ssize_t n;
  +    apr_size_t n;
   
       if (fb->flags & B_CHUNK) {
   	end_chunk(fb, 0);
  @@ -994,7 +994,7 @@
    * state.
    */
   AP_DECLARE(apr_status_t) ap_bwrite_core(BUFF *fb, const void *buf, apr_size_t nbyte,
  -                                  apr_ssize_t *bytes_written)
  +                                  apr_size_t *bytes_written)
   {
       int amt;
       int total;
  @@ -1124,7 +1124,7 @@
   {
       apr_status_t rv;
       int j = strlen(x);
  -    apr_ssize_t i;
  +    apr_size_t i;
       rv = ap_bwrite(fb, x, j, &i);
       if (i != j) {
           fb->berrno = rv;
  @@ -1140,7 +1140,7 @@
   AP_DECLARE(int) ap_vbputstrs(BUFF *fb, va_list va)
   {
       int j, k;
  -    apr_ssize_t i;
  +    apr_size_t i;
       const char *x;
       int rv;
   
  
  
  
  1.130     +2 -2      apache-2.0/src/modules/mpm/dexter/dexter.c
  
  Index: dexter.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/modules/mpm/dexter/dexter.c,v
  retrieving revision 1.129
  retrieving revision 1.130
  diff -u -r1.129 -r1.130
  --- dexter.c	2000/10/23 10:54:14	1.129
  +++ dexter.c	2000/11/10 19:01:31	1.130
  @@ -474,7 +474,7 @@
       if (!workers_may_exit) {
           int ret;
           char pipe_read_char;
  -        apr_ssize_t n = 1;
  +        apr_size_t n = 1;
   
           ret = apr_recv(listenfds[0], &pipe_read_char, &n);
           if (APR_STATUS_IS_EAGAIN(ret)) {
  @@ -977,7 +977,7 @@
       int remaining_children_to_start;
       int i;
       apr_status_t rv;
  -    apr_ssize_t one = 1;
  +    apr_size_t one = 1;
   
       pconf = _pconf;
       ap_server_conf = s;
  
  
  
  1.125     +3 -3      apache-2.0/src/modules/mpm/mpmt_pthread/mpmt_pthread.c
  
  Index: mpmt_pthread.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/modules/mpm/mpmt_pthread/mpmt_pthread.c,v
  retrieving revision 1.124
  retrieving revision 1.125
  diff -u -r1.124 -r1.125
  --- mpmt_pthread.c	2000/10/23 10:54:15	1.124
  +++ mpmt_pthread.c	2000/11/10 19:01:31	1.125
  @@ -426,7 +426,7 @@
       if (!workers_may_exit) {
           apr_status_t ret;
           char pipe_read_char;
  -	apr_ssize_t n = 1;
  +	apr_size_t n = 1;
   
           ret = apr_recv(listensocks[0], &pipe_read_char, &n);
           if (APR_STATUS_IS_EAGAIN(ret)) {
  @@ -822,7 +822,7 @@
       int free_slots[MAX_SPAWN_RATE];
       int last_non_dead;
       int total_non_dead;
  -    apr_ssize_t one = 1;
  +    apr_size_t one = 1;
       apr_status_t rv;
   
       /* initialize the free_list */
  @@ -998,7 +998,7 @@
   {
       int remaining_children_to_start;
       apr_status_t rv;
  -    apr_ssize_t one = 1;
  +    apr_size_t one = 1;
   
       pconf = _pconf;
       ap_server_conf = s;
  
  
  
  1.25      +2 -2      apache-2.0/src/modules/mpm/perchild/perchild.c
  
  Index: perchild.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/modules/mpm/perchild/perchild.c,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -r1.24 -r1.25
  --- perchild.c	2000/10/23 10:54:16	1.24
  +++ perchild.c	2000/11/10 19:01:32	1.25
  @@ -512,7 +512,7 @@
       if (!workers_may_exit) {
           int ret;
           char pipe_read_char;
  -        apr_ssize_t n = 1;
  +        apr_size_t n = 1;
   
           ret = apr_recv(listenfds[0], &pipe_read_char, &n);
           if (APR_STATUS_IS_EAGAIN(ret)) {
  @@ -1138,7 +1138,7 @@
       int remaining_children_to_start;
       int i;
       apr_status_t rv;
  -    apr_ssize_t one = 1;
  +    apr_size_t one = 1;
   
       pconf = _pconf;
       ap_server_conf = s;
  
  
  
  1.46      +2 -2      apache-2.0/src/modules/standard/mod_autoindex.c
  
  Index: mod_autoindex.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/modules/standard/mod_autoindex.c,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -r1.45 -r1.46
  --- mod_autoindex.c	2000/11/02 20:01:52	1.45
  +++ mod_autoindex.c	2000/11/10 19:01:32	1.46
  @@ -912,7 +912,7 @@
   {
       char buf[IOBUFSIZE + 1];
       int i, c, ch;
  -    apr_ssize_t n;
  +    apr_size_t n;
       apr_status_t stat;
   
       ap_rputs("<PRE>\n", r);
  @@ -1106,7 +1106,7 @@
       char titlebuf[MAX_STRING_LEN], *find = "<TITLE>";
       apr_file_t *thefile = NULL;
       int x, y, p;
  -    apr_ssize_t n;
  +    apr_size_t n;
   
       if (r->status != HTTP_OK) {
   	return NULL;
  
  
  
  1.49      +1 -1      apache-2.0/src/modules/standard/mod_cgid.c
  
  Index: mod_cgid.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/modules/standard/mod_cgid.c,v
  retrieving revision 1.48
  retrieving revision 1.49
  diff -u -r1.48 -r1.49
  --- mod_cgid.c	2000/10/23 15:30:53	1.48
  +++ mod_cgid.c	2000/11/10 19:01:32	1.49
  @@ -745,7 +745,7 @@
       char **env; 
       struct sockaddr_un unix_addr;
       apr_file_t *tempsock = NULL;
  -    apr_ssize_t nbytes;
  +    apr_size_t nbytes;
   
       if (r->method_number == M_OPTIONS) { 
           /* 99 out of 100 cgid scripts, this is all they support */ 
  
  
  
  1.74      +3 -3      apache-2.0/src/modules/standard/mod_include.c
  
  Index: mod_include.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/modules/standard/mod_include.c,v
  retrieving revision 1.73
  retrieving revision 1.74
  diff -u -r1.73 -r1.74
  --- mod_include.c	2000/10/24 18:40:00	1.73
  +++ mod_include.c	2000/11/10 19:01:32	1.74
  @@ -185,7 +185,7 @@
   
   static ap_bucket *find_string(ap_bucket *dptr, const char *str, ap_bucket *end)
   {
  -    apr_ssize_t len;
  +    apr_size_t len;
       const char *c;
       const char *buf;
       int state = 0;
  @@ -341,7 +341,7 @@
       ap_bucket *dptr = in;
       const char *c;
       const char *str;
  -    apr_ssize_t length; 
  +    apr_size_t length; 
       char *t = tag, *tag_val, term;
   
       /* makes code below a little less cluttered */
  @@ -475,7 +475,7 @@
       char *d = dest;
       const char *c;
       const char *str;
  -    apr_ssize_t length; 
  +    apr_size_t length; 
   
       /* make room for nul terminator */
       --len;
  
  
  
  1.41      +3 -3      apache-2.0/src/modules/standard/mod_log_config.c
  
  Index: mod_log_config.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/modules/standard/mod_log_config.c,v
  retrieving revision 1.40
  retrieving revision 1.41
  diff -u -r1.40 -r1.41
  --- mod_log_config.c	2000/11/07 00:58:49	1.40
  +++ mod_log_config.c	2000/11/10 19:01:32	1.41
  @@ -255,7 +255,7 @@
       apr_file_t *log_fd;
       char *condition_var;
   #ifdef BUFFERED_LOGS
  -    apr_ssize_t outcnt;
  +    apr_size_t outcnt;
       char outbuf[LOG_BUFSIZE];
   #endif
   } config_log_state;
  @@ -828,7 +828,7 @@
       int *strl;
       request_rec *orig;
       int i;
  -    apr_ssize_t len = 0;
  +    apr_size_t len = 0;
       apr_array_header_t *format;
       char *envar;
   
  @@ -881,7 +881,7 @@
           flush_log(cls);
       }
       if (len >= LOG_BUFSIZE) {
  -        apr_ssize_t w;
  +        apr_size_t w;
   
           str = apr_palloc(r->pool, len + 1);
           for (i = 0, s = str; i < format->nelts; ++i) {
  
  
  
  1.32      +7 -7      apache-2.0/src/support/ab.c
  
  Index: ab.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/support/ab.c,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- ab.c	2000/11/08 18:41:45	1.31
  +++ ab.c	2000/11/10 19:01:33	1.32
  @@ -183,7 +183,7 @@
   char path[1024];        	/* path name */
   char postfile[1024];        /* name of file containing post data */
   char *postdata;        		/* *buffer containing data from postfile */
  -apr_ssize_t postlen = 0;    /* length of data to be POSTed */
  +apr_size_t postlen = 0;    /* length of data to be POSTed */
   char content_type[1024];    /* content type to put in POST header */
   char cookie[1024],        	/* optional cookie line */
        auth[1024],        	/* optional (basic/uuencoded)
  @@ -214,7 +214,7 @@
   
   /* global request (and its length) */
   char request[512];
  -apr_ssize_t reqlen;
  +apr_size_t reqlen;
   
   /* one global throw-away buffer to read stuff into */
   char buffer[8192];
  @@ -258,7 +258,7 @@
   
   static void write_request(struct connection *c)
   {
  -    apr_ssize_t len = reqlen;
  +    apr_size_t len = reqlen;
       c->connect = apr_now();
       apr_setsocketopt(c->aprsock, APR_SO_TIMEOUT, aprtimeout);
       if (apr_send(c->aprsock, request, &reqlen) != APR_SUCCESS ||
  @@ -569,7 +569,7 @@
   
   static void read_connection(struct connection *c)
   {
  -    apr_ssize_t r;
  +    apr_size_t r;
       apr_status_t status;
       char *part;
       char respcode[4];        	/* 3 digits and null */
  @@ -876,14 +876,14 @@
   static void copyright(void)
   {
       if (!use_html) {
  -        printf("This is ApacheBench, Version %s\n", AB_VERSION " <$Revision: 1.31 $>
apache-2.0");
  +        printf("This is ApacheBench, Version %s\n", AB_VERSION " <$Revision: 1.32 $>
apache-2.0");
           printf("Copyright (c) 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/\n");
           printf("Copyright (c) 1998-2000 The Apache Software Foundation, http://www.apache.org/\n");
           printf("\n");
       }
       else {
           printf("<p>\n");
  -        printf(" This is ApacheBench, Version %s <i>&lt;%s&gt;</i>
apache-2.0<br>\n", AB_VERSION, "$Revision: 1.31 $");
  +        printf(" This is ApacheBench, Version %s <i>&lt;%s&gt;</i>
apache-2.0<br>\n", AB_VERSION, "$Revision: 1.32 $");
           printf(" Copyright (c) 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/<br>\n");
           printf(" Copyright (c) 1998-2000 The Apache Software Foundation, http://www.apache.org/<br>\n");
           printf("</p>\n<p>\n");
  @@ -956,7 +956,7 @@
       apr_file_t *postfd = NULL;
       apr_finfo_t finfo;
       apr_fileperms_t mode = APR_OS_DEFAULT;
  -    apr_ssize_t length;
  +    apr_size_t length;
   
       if (apr_open(&postfd, pfile, APR_READ, mode, cntxt) != APR_SUCCESS) {
           printf("Invalid postfile name (%s)\n", pfile);
  
  
  

Mime
View raw message