apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wr...@apache.org
Subject cvs commit: apr/file_io/win32 open.c
Date Mon, 08 Oct 2001 17:33:14 GMT
wrowe       01/10/08 10:33:14

  Modified:    file_io/win32 open.c
  Log:
    Forgot to update chars to decode and used the wrong buffer remaining var
  
  Revision  Changes    Path
  1.83      +2 -2      apr/file_io/win32/open.c
  
  Index: open.c
  ===================================================================
  RCS file: /home/cvs/apr/file_io/win32/open.c,v
  retrieving revision 1.82
  retrieving revision 1.83
  diff -u -r1.82 -r1.83
  --- open.c	2001/09/05 04:50:30	1.82
  +++ open.c	2001/10/08 17:33:14	1.83
  @@ -81,7 +81,6 @@
        * \\?\UNC\ is needed UNC paths.
        */
       int srcremains = strlen(srcstr) + 1;
  -    int retremains = srcremains;
       apr_wchar_t *t = retstr;
       apr_status_t rv;
       if (srcstr[1] == ':' && (srcstr[2] == '/' || srcstr[2] == '\\')) {
  @@ -94,12 +93,13 @@
             && (srcstr[2] != '?')) {
           /* Skip the slashes */
           srcstr += 2;
  +        srcremains -= 2;
           wcscpy (retstr, L"\\\\?\\UNC\\");
           retlen -= 8;
           t += 8;
       }
   
  -    if (rv = conv_utf8_to_ucs2(srcstr, &srcremains, t, &retremains)) {
  +    if (rv = conv_utf8_to_ucs2(srcstr, &srcremains, t, &retlen)) {
           return (rv == APR_INCOMPLETE) ? APR_EINVAL : rv;
       }
       if (srcremains) {
  
  
  

Mime
View raw message