httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <dgau...@hyperreal.com>
Subject cvs commit: apache/src http_protocol.c
Date Sun, 29 Jun 1997 17:56:48 GMT
dgaudet     97/06/29 10:56:48

  Modified:    src       http_protocol.c
  Log:
  Turn an O(n^2) loop into an O(n) loop.
  
  Revision  Changes    Path
  1.129     +3 -2      apache/src/http_protocol.c
  
  Index: http_protocol.c
  ===================================================================
  RCS file: /export/home/cvs/apache/src/http_protocol.c,v
  retrieving revision 1.128
  retrieving revision 1.129
  diff -C3 -r1.128 -r1.129
  *** http_protocol.c	1997/06/29 17:43:54	1.128
  --- http_protocol.c	1997/06/29 17:56:47	1.129
  ***************
  *** 505,511 ****
    
    #if defined(__EMX__) || defined(WIN32)
        /* Variable for OS/2 fix below. */
  !     size_t loop;
    #endif
    
    /* A proxy request contains a ':' early on, but not as first character */
  --- 505,511 ----
    
    #if defined(__EMX__) || defined(WIN32)
        /* Variable for OS/2 fix below. */
  !     size_t loop, uri_len;
    #endif
    
    /* A proxy request contains a ':' early on, but not as first character */
  ***************
  *** 531,537 ****
        /* Handle path translations for OS/2 and plug security hole. */
        /* This will prevent "http://www.wherever.com/..\..\/" from
           returning a directory for the root drive. */
  !     for (loop = 0; loop <= strlen(r->uri); ++loop) {
            if (r->uri[loop] == '\\')
                r->uri[loop] = '/';
        };
  --- 531,538 ----
        /* Handle path translations for OS/2 and plug security hole. */
        /* This will prevent "http://www.wherever.com/..\..\/" from
           returning a directory for the root drive. */
  !     uri_len = strlen(r->uri);
  !     for (loop = 0; loop < uri_len; ++loop) {
            if (r->uri[loop] == '\\')
                r->uri[loop] = '/';
        };
  
  
  

Mime
View raw message