fix •file.Type and •file.Exists on links

This commit is contained in:
dzaima 2025-05-19 23:51:13 +03:00
parent 1ab511f657
commit 8046f157bf

View File

@ -438,7 +438,7 @@ bool path_remove(B path) {
int path_stat(struct stat* s, B path) { // doesn't consume; get stat of s; errors if path isn't string; returns non-zero on failure int path_stat(struct stat* s, B path) { // doesn't consume; get stat of s; errors if path isn't string; returns non-zero on failure
OsStr p = toOsStr(path); OsStr p = toOsStr(path);
#if !defined(_WIN32) #if !defined(_WIN32)
int r = stat(p, s); int r = lstat(p, s);
#else #else
int r = wstat(p, s); int r = wstat(p, s);
#endif #endif