diff options
| author | Paul Eggert | 2017-10-09 10:47:56 -0700 |
|---|---|---|
| committer | Paul Eggert | 2017-10-09 10:48:56 -0700 |
| commit | f352d0257ce5ca1d424b55fc179f18b81bd465ab (patch) | |
| tree | 03bb6df8efc7ff8c820d709bf41e8f521ae21104 /src | |
| parent | 934f08f3de7929e54e9da3271a34bb49a8854f2c (diff) | |
| download | emacs-f352d0257ce5ca1d424b55fc179f18b81bd465ab.tar.gz emacs-f352d0257ce5ca1d424b55fc179f18b81bd465ab.zip | |
Fix PWD check on DOS_NT
* src/sysdep.c (get_current_dir_name_or_unreachable):
Do not consider a file name like "a:b" to be absolute on DOS_NT.
Diffstat (limited to 'src')
| -rw-r--r-- | src/sysdep.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sysdep.c b/src/sysdep.c index 6d24b7fa2b1..dd0062b6f04 100644 --- a/src/sysdep.c +++ b/src/sysdep.c | |||
| @@ -274,8 +274,8 @@ get_current_dir_name_or_unreachable (void) | |||
| 274 | sometimes a nicer name, and using it may avoid a fatal error if a | 274 | sometimes a nicer name, and using it may avoid a fatal error if a |
| 275 | parent directory is searchable but not readable. */ | 275 | parent directory is searchable but not readable. */ |
| 276 | if (pwd | 276 | if (pwd |
| 277 | && (IS_DIRECTORY_SEP (*pwd) || (*pwd && IS_DEVICE_SEP (pwd[1]))) | ||
| 278 | && (pwdlen = strlen (pwd)) < bufsize_max | 277 | && (pwdlen = strlen (pwd)) < bufsize_max |
| 278 | && IS_DIRECTORY_SEP (pwd[pwdlen && IS_DEVICE_SEP (pwd[1]) ? 2 : 0]) | ||
| 279 | && stat (pwd, &pwdstat) == 0 | 279 | && stat (pwd, &pwdstat) == 0 |
| 280 | && stat (".", &dotstat) == 0 | 280 | && stat (".", &dotstat) == 0 |
| 281 | && dotstat.st_ino == pwdstat.st_ino | 281 | && dotstat.st_ino == pwdstat.st_ino |