scummvm/backends/fs
Donovan Watteau 858847e1ba BACKENDS: FS: Use stat() fallback for all unexpected dirent d_type values
On systems where dirent provides a `d_type` field, we currently fall
back to stat() only for DT_UNKNOWN values.

Do so for all unexpected `d_type` values instead (that is, anything
different from DT_DIR, DT_REG and DT_LNK).

This is because there's no guarantee that `d_type` will be meaningful
for all OSes and filesystems. One such example is macOS Tiger, where
`d_type` will hold bogus values for the .aiff files of cddafs mount
points (as triggered by MacOSXAudioCDManager). (This bug appears to
have been fixed in cddafs-242.0.1, around the Snow Leopard area.)

When using stat() over the same files, the proper file type is
returned, though. Hence the need for the stat() fallback to be
triggered in more cases than DT_UNKNOWN.

This fixes Indy3 FM-TOWNS music being silent on macOS Tiger, when
playing from the original CD.
2025-03-26 11:50:53 +08:00
..
amigaos JANITORIAL: Add missing closing bracket in amigaos-fs.cpp 2024-11-10 14:49:50 +02:00
android ANDROID: Don't track SAFFSNode using JNI global references anymore 2025-01-26 18:17:05 +01:00
chroot BACKENDS: Allow write streams to be created atomically 2024-10-15 22:45:50 +02:00
devoptab
kolibrios KOLIBRI: Use _ksys_getcwd instead of getcwd 2024-12-06 17:17:11 +02:00
morphos BACKENDS: MORPHOS: enhanced init and add features 2024-11-23 19:24:02 +02:00
n64 BACKENDS: Allow write streams to be created atomically 2024-10-15 22:45:50 +02:00
posix BACKENDS: FS: Use stat() fallback for all unexpected dirent d_type values 2025-03-26 11:50:53 +08:00
posix-drives BACKENDS: FS: Implement atomic file write for stdio stream backend 2024-10-15 22:45:50 +02:00
ps3
psp BACKENDS: Allow write streams to be created atomically 2024-10-15 22:45:50 +02:00
riscos BACKENDS: FS: Implement atomic file write for stdio stream backend 2024-10-15 22:45:50 +02:00
wii BACKENDS: FS: Implement atomic file write for stdio stream backend 2024-10-15 22:45:50 +02:00
windows BACKENDS: FS: Implement atomic file write for stdio stream backend 2024-10-15 22:45:50 +02:00
abstract-fs.cpp COMMON: Add createReadStreamForAltStream to open Mac resource fork and metadata streams 2023-08-30 00:31:00 +02:00
abstract-fs.h BACKENDS: Allow write streams to be created atomically 2024-10-15 22:45:50 +02:00
fs-factory.h BACKENDS: Add function in FS Factory to map scummvm path to system path 2023-12-03 16:17:32 +00:00
stdiostream.cpp RISCOS: Don't encode path when it's not needed 2024-12-04 22:41:14 +00:00
stdiostream.h JANITORIAL: Fix typos in general files 2024-12-25 16:57:34 +02:00