git/list[1] front-page[2] threads[3] people[4] search[5] about
 

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
Next: René Scharfe
Message 1 of 4 in “Bug in get_pwd_cwd() in Windows?”
  1. Duy NguyenJul 21, 2014
  2. René ScharfeJul 22, 2014
  3. Duy NguyenJul 23, 2014
  4. Karsten BleesJul 23, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.