Open FrankHB opened 1 year ago
On Windows 11, I used mklink to create a symbolic link from foo.ss to bar.ss. In Chez Scheme 9.5.8, (file-exists? "bar.ss") returned #t. However, (load "bar.ss") failed with "no such file or directory".
This means that GetFileAttributesExW is following the link, but whatever Chez Scheme calls to open the file is not.
Do you know how to modify S_file_existsp to use followp on Windows?
https://github.com/cisco/ChezScheme/blob/c048ad8423791de4bf650fca00519d5c2059d66e/c/io.c#L127-L195
In these implementations,
followp
is not used at all for Win32. This looks wrong, because Windows supports symbolic links similar enough to POSIX. There is no reason to keep the inconsistent behaviors. Further, the behavior is also not the default of POSIX, due to the fact thatGetFileAttributesExW
does not follow links (i.e. it is more likelstat
but notstat
). These gliches are not documented.