Mercurial > hg > xemacs-beta
comparison src/nt.c @ 263:727739f917cb r20-5b30
Import from CVS: tag r20-5b30
author | cvs |
---|---|
date | Mon, 13 Aug 2007 10:24:41 +0200 |
parents | 41f2f0e326e9 |
children | c5d627a313b1 |
comparison
equal
deleted
inserted
replaced
262:9d8607af9e13 | 263:727739f917cb |
---|---|
87 #include "nt.h" | 87 #include "nt.h" |
88 #include <sys/dir.h> | 88 #include <sys/dir.h> |
89 #include "ntheap.h" | 89 #include "ntheap.h" |
90 | 90 |
91 | 91 |
92 extern Lisp_Object Vwin32_downcase_file_names; | 92 extern Lisp_Object Vmswindows_downcase_file_names; |
93 #if 0 | |
93 extern Lisp_Object Vwin32_generate_fake_inodes; | 94 extern Lisp_Object Vwin32_generate_fake_inodes; |
94 extern Lisp_Object Vwin32_get_true_file_attributes; | 95 #endif |
96 extern Lisp_Object Vmswindows_get_true_file_attributes; | |
95 | 97 |
96 static char startup_dir[ MAXPATHLEN ]; | 98 static char startup_dir[ MAXPATHLEN ]; |
97 | 99 |
98 /* Get the current working directory. */ | 100 /* Get the current working directory. */ |
99 char * | 101 char * |
322 { | 324 { |
323 *fp += 'a' - 'A'; | 325 *fp += 'a' - 'A'; |
324 fp += 2; | 326 fp += 2; |
325 } | 327 } |
326 | 328 |
327 if (NILP (Vwin32_downcase_file_names)) | 329 if (NILP (Vmswindows_downcase_file_names)) |
328 { | 330 { |
329 while (*fp) | 331 while (*fp) |
330 { | 332 { |
331 if (*fp == '/' || *fp == '\\') | 333 if (*fp == '/' || *fp == '\\') |
332 *fp = path_sep; | 334 *fp = path_sep; |
1213 | 1215 |
1214 dir_static.d_namlen = strlen (dir_find_data.cFileName); | 1216 dir_static.d_namlen = strlen (dir_find_data.cFileName); |
1215 strcpy (dir_static.d_name, dir_find_data.cFileName); | 1217 strcpy (dir_static.d_name, dir_find_data.cFileName); |
1216 if (dir_is_fat) | 1218 if (dir_is_fat) |
1217 _strlwr (dir_static.d_name); | 1219 _strlwr (dir_static.d_name); |
1218 else if (!NILP (Vwin32_downcase_file_names)) | 1220 else if (!NILP (Vmswindows_downcase_file_names)) |
1219 { | 1221 { |
1220 REGISTER char *p; | 1222 REGISTER char *p; |
1221 for (p = dir_static.d_name; *p; p++) | 1223 for (p = dir_static.d_name; *p; p++) |
1222 if (*p >= 'a' && *p <= 'z') | 1224 if (*p >= 'a' && *p <= 'z') |
1223 break; | 1225 break; |
1522 | 1524 |
1523 static FILETIME utc_base_ft; | 1525 static FILETIME utc_base_ft; |
1524 static long double utc_base; | 1526 static long double utc_base; |
1525 static int init = 0; | 1527 static int init = 0; |
1526 | 1528 |
1527 static time_t | 1529 time_t |
1528 convert_time (FILETIME ft) | 1530 convert_time (FILETIME ft) |
1529 { | 1531 { |
1530 long double ret; | 1532 long double ret; |
1531 | 1533 |
1532 if (!init) | 1534 if (!init) |
1717 { | 1719 { |
1718 buf->st_mode = _S_IFDIR; | 1720 buf->st_mode = _S_IFDIR; |
1719 buf->st_nlink = 2; /* doesn't really matter */ | 1721 buf->st_nlink = 2; /* doesn't really matter */ |
1720 fake_inode = 0; /* this doesn't either I think */ | 1722 fake_inode = 0; /* this doesn't either I think */ |
1721 } | 1723 } |
1722 else if (!NILP (Vwin32_get_true_file_attributes)) | 1724 else if (!NILP (Vmswindows_get_true_file_attributes)) |
1723 { | 1725 { |
1724 /* This is more accurate in terms of gettting the correct number | 1726 /* This is more accurate in terms of gettting the correct number |
1725 of links, but is quite slow (it is noticable when Emacs is | 1727 of links, but is quite slow (it is noticable when Emacs is |
1726 making a list of file name completions). */ | 1728 making a list of file name completions). */ |
1727 BY_HANDLE_FILE_INFORMATION info; | 1729 BY_HANDLE_FILE_INFORMATION info; |