httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wr...@apache.org
Subject cvs commit: httpd-2.0/os/win32 util_win32.c
Date Thu, 01 Feb 2001 15:58:11 GMT
wrowe       01/02/01 07:58:11

  Modified:    os/win32 util_win32.c
  Log:
    This file will go away.  For this moment, the s/FindFirstFile/apr_stat/
    fixes parsing of utf-8 resources against the NTFS filesystem.  The only
    remaining utf-8 change is to the config parser [which is simple - any
    unicode config file (FFFE/FEFF lead word) will be utf-8 encrypted].
  
  Revision  Changes    Path
  1.22      +4 -9      httpd-2.0/os/win32/util_win32.c
  
  Index: util_win32.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/os/win32/util_win32.c,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -r1.21 -r1.22
  --- util_win32.c	2000/11/26 04:47:36	1.21
  +++ util_win32.c	2001/02/01 15:58:09	1.22
  @@ -94,8 +94,6 @@
       char *p, *q, *t;
       BOOL bDone = FALSE;
       BOOL bFileExists = TRUE;
  -    HANDLE hFind;
  -    WIN32_FIND_DATA wfd;
   
       if (!szFile || strlen(szFile) == 0 || strlen(szFile) >= sizeof(buf))
           return apr_pstrdup(pPool, "");
  @@ -178,18 +176,15 @@
            * Note: in the call to OnlyDots, we may have to skip
            *       a leading slash.
            */
  -        if (bFileExists && !OnlyDots((*q == '.' ? q : q+1))) {            
  -            hFind = FindFirstFile(pInputName, &wfd);
  -            
  -            if (hFind == INVALID_HANDLE_VALUE) {
  +        if (bFileExists && !OnlyDots((*q == '.' ? q : q+1))) {
  +            apr_finfo_t fs;
  +            if (apr_stat(&fs, pInputName, APR_FINFO_NAME, pPool) != APR_SUCCESS) {
                   bFileExists = FALSE;
               }
               else {
  -                FindClose(hFind);
  -
                   if (*q == '\\')
                       *(t++) = '\\';
  -                t = strchr(strcpy(t, wfd.cFileName), '\0');
  +                t = strchr(strcpy(t, fs.name), '\0');
               }
           }
           
  
  
  

Mime
View raw message