Diff for /np2/x11/dosio.c between versions 1.14 and 1.17

version 1.14, 2005/03/09 16:13:24 version 1.17, 2011/01/15 14:56:55
Line 223  file_attr_c(const OEMCHAR *filename) Line 223  file_attr_c(const OEMCHAR *filename)
   
         *curfilep = '\0';          *curfilep = '\0';
         file_catname(curpath, filename, sizeof(curpath));          file_catname(curpath, filename, sizeof(curpath));
         return file_attr_c(curpath);          return file_attr(curpath);
 }  }
   
 FLISTH  FLISTH
Line 352  file_catname(OEMCHAR *path, const OEMCHA Line 352  file_catname(OEMCHAR *path, const OEMCHA
                         } else if (((*path - 0x41) & 0xff) < 26) {                          } else if (((*path - 0x41) & 0xff) < 26) {
                                 *path |= 0x20;                                  *path |= 0x20;
                         } else if (*path == '\\') {                          } else if (*path == '\\') {
                                 *path = '/';                                  *path = G_DIR_SEPARATOR;
                         }                          }
                 }                  }
         }          }
Line 362  BOOL Line 362  BOOL
 file_cmpname(const OEMCHAR *path, const OEMCHAR *path2)  file_cmpname(const OEMCHAR *path, const OEMCHAR *path2)
 {  {
   
         return strcmp(path, path2);          return strcasecmp(path, path2);
 }  }
   
 OEMCHAR *  OEMCHAR *
Line 376  file_getname(const OEMCHAR *path) Line 376  file_getname(const OEMCHAR *path)
                         if (*path == '\0') {                          if (*path == '\0') {
                                 break;                                  break;
                         }                          }
                 } else if (*path == '/') {                  } else if (*path == G_DIR_SEPARATOR) {
                         ret = path + 1;                          ret = path + 1;
                 }                  }
         }          }
Line 429  file_cutseparator(OEMCHAR *path) Line 429  file_cutseparator(OEMCHAR *path)
         int pos;          int pos;
   
         pos = strlen(path) - 1;          pos = strlen(path) - 1;
         if ((pos > 0) && (path[pos] == '/')) {          if ((pos > 0) && (path[pos] == G_DIR_SEPARATOR)) {
                 path[pos] = '\0';                  path[pos] = '\0';
         }          }
 }  }
Line 440  file_setseparator(OEMCHAR *path, int max Line 440  file_setseparator(OEMCHAR *path, int max
         int pos;          int pos;
   
         pos = strlen(path);          pos = strlen(path);
         if ((pos) && (path[pos-1] != '/') && ((pos + 2) < maxlen)) {          if ((pos) && (path[pos-1] != G_DIR_SEPARATOR) && ((pos + 2) < maxlen)) {
                 path[pos++] = '/';                  path[pos++] = G_DIR_SEPARATOR;
                 path[pos] = '\0';                  path[pos] = '\0';
         }          }
 }  }

Removed from v.1.14  
changed lines
  Added in v.1.17


RetroPC.NET-CVS <cvs@retropc.net>