httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wsanc...@apache.org
Subject cvs commit: httpd-2.0/modules/mappers mod_negotiation.c
Date Wed, 24 Jul 2002 20:47:29 GMT
wsanchez    2002/07/24 13:47:29

  Modified:    .        CHANGES
               modules/dav/main mod_dav.c
               modules/experimental mod_cache.c
               modules/http http_protocol.c
               modules/mappers mod_negotiation.c
  Log:
  Replace atol() calls which should return long long with apr_atoll() calls.
  Submitted by: Shantonu Sen <ssen@apple.com>
  
  Revision  Changes    Path
  1.873     +5 -0      httpd-2.0/CHANGES
  
  Index: CHANGES
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/CHANGES,v
  retrieving revision 1.872
  retrieving revision 1.873
  diff -u -r1.872 -r1.873
  --- CHANGES	19 Jul 2002 11:43:16 -0000	1.872
  +++ CHANGES	24 Jul 2002 20:47:27 -0000	1.873
  @@ -1,5 +1,10 @@
   Changes with Apache 2.0.40
   
  +  *) Replace usage of atol() to parse strings when we might want a
  +     larger-than-long value with apr_atoll(), which returns long long.
  +     This allows HTTPD to deal with larger files correctly.
  +     [Shantonu Sen <ssen@apple.com>]
  +
     *) mod_ext_filter: Ignore any content-type parameters when checking if
        the response should be filtered.  Previously, "intype=text/html"
        wouldn't match something like "text/html;charset=8859_1".
  
  
  
  1.83      +4 -5      httpd-2.0/modules/dav/main/mod_dav.c
  
  Index: mod_dav.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/dav/main/mod_dav.c,v
  retrieving revision 1.82
  retrieving revision 1.83
  diff -u -r1.82 -r1.83
  --- mod_dav.c	23 Jun 2002 06:42:13 -0000	1.82
  +++ mod_dav.c	24 Jul 2002 20:47:28 -0000	1.83
  @@ -761,12 +761,11 @@
   
       *dash = *slash = '\0';
   
  -    /* ### atol may not be large enough for the apr_off_t */
  -    *range_start = atol(range + 6);
  -    *range_end = atol(dash + 1);
  +    *range_start = apr_atoll(range + 6);
  +    *range_end = apr_atoll(dash + 1);
   
       if (*range_end < *range_start
  -        || (slash[1] != '*' && atol(slash + 1) <= *range_end)) {
  +        || (slash[1] != '*' && apr_atoll(slash + 1) <= *range_end)) {
           /* invalid range. ignore it (per S14.16 of RFC2616) */
           return 0;
       }
  @@ -2319,7 +2318,7 @@
               return HTTP_BAD_REQUEST;
           }
   
  -        r->remaining = atol(lenp);
  +        r->remaining = apr_atoll(lenp);
       }
   
       if (r->read_chunked || r->remaining > 0) {
  
  
  
  1.49      +1 -1      httpd-2.0/modules/experimental/mod_cache.c
  
  Index: mod_cache.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/experimental/mod_cache.c,v
  retrieving revision 1.48
  retrieving revision 1.49
  diff -u -r1.48 -r1.49
  --- mod_cache.c	24 Jul 2002 17:21:45 -0000	1.48
  +++ mod_cache.c	24 Jul 2002 20:47:28 -0000	1.49
  @@ -577,7 +577,7 @@
           const char* cl;
           cl = apr_table_get(r->headers_out, "Content-Length");
           if (cl) {
  -            size = atol(cl);
  +            size = apr_atoll(cl);
           }
           else {
   
  
  
  
  1.450     +3 -3      httpd-2.0/modules/http/http_protocol.c
  
  Index: http_protocol.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/http/http_protocol.c,v
  retrieving revision 1.449
  retrieving revision 1.450
  diff -u -r1.449 -r1.450
  --- http_protocol.c	17 Jul 2002 19:18:39 -0000	1.449
  +++ http_protocol.c	24 Jul 2002 20:47:28 -0000	1.450
  @@ -2719,15 +2719,15 @@
   
       if ((dash == range)) {
           /* In the form "-5" */
  -        *start = clength - atol(dash + 1);
  +        *start = clength - apr_atoll(dash + 1);
           *end = clength - 1;
       }
       else {
           *dash = '\0';
           dash++;
  -        *start = atol(range);
  +        *start = apr_atoll(range);
           if (*dash) {
  -            *end = atol(dash);
  +            *end = apr_atoll(dash);
           }
           else {                  /* "5-" */
               *end = clength - 1;
  
  
  
  1.104     +1 -1      httpd-2.0/modules/mappers/mod_negotiation.c
  
  Index: mod_negotiation.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/mappers/mod_negotiation.c,v
  retrieving revision 1.103
  retrieving revision 1.104
  diff -u -r1.103 -r1.104
  --- mod_negotiation.c	10 Jul 2002 06:01:10 -0000	1.103
  +++ mod_negotiation.c	24 Jul 2002 20:47:28 -0000	1.104
  @@ -948,7 +948,7 @@
                   has_content = 1;
               }
               else if (!strncmp(buffer, "content-length:", 15)) {
  -                mime_info.bytes = atol(body);
  +                mime_info.bytes = apr_atoll((char *)body);
                   has_content = 1;
               }
               else if (!strncmp(buffer, "content-language:", 17)) {
  
  
  

Mime
View raw message