Bug in get_pwd_cwd() in Windows?
- From
Duy Nguyen <pclouds@gmail.com>
- Date
- Jul 21, 2014, 14:13 UTC
- Message-ID
- <CACsJy8BY8pyuZ0eY7qK86RGUh8Vp9FVE55TskcQhBTrwwPowEQ@mail.gmail.com>
This function tests if $PWD is the same as getcwd() using st_dev and st_ino. But on Windows these fields are always zero (mingw.c:do_lstat). If cwd is moved away, I think falling back to $PWD is wrong. I don't understand the use of $PWD in the first place. 1b9a946 (Use nonrelative paths instead of absolute paths for cloned repositories - 2008-06-05) does not explain much.
-- Duy