mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-09-07 21:23:29 +02:00
DirectoryFileSystem passed the host's permission bits and directory size straight through to the game. The PSP has neither - its FAT driver makes a mode up from the entry type and whether it's writable, and reports no size for a directory. So a game saw 0644/0755 and a 4096 byte directory on Linux, but 0664/0777 and 0 on Windows, where the file layer already synthesizes those bits. Now both platforms report what the PSP does: 0777 for directories, 0664 for writable files, 0444 for read-only ones, and no size on a directory. The parent ".." entry keeps its 4096, which is what the hardware reports for that one. Also fixes the synthetic PSP directory entry using 0x777 where 0777 was meant. Fixes io/directory/directory, moved to tests_good. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>