16 Nov
2024
16 Nov
'24
4:36 a.m.
Jinoh Kang (@iamahuman) commented about server/fd.c:
if (!fstat( fd->unix_fd, &st2 ) && st.st_ino == st2.st_ino && st.st_dev == st2.st_dev) { if (create_link && !replace) set_error( STATUS_OBJECT_NAME_COLLISION ); + if (!different_case) + { free( name ); return; }
+ /* creating a link with a different case on itself renames the file */ + create_link = 0;
What if the destination file is a hard link to the same file as the source, but with a completely different name (not just different case)? -- https://gitlab.winehq.org/wine/wine/-/merge_requests/246#note_87708