[physfs] Making PHYSFS_FILETYPE_* a bitmask

Indy Sams indy at driftsolutions.com
Wed Apr 25 17:37:00 EDT 2012


Hello all,

Just throwing this idea out there to see what people think. In the PHYSFS_Stat structure would could make the filetype a bitmask instead of an enum. The reason being that if the file or directory you PHYSFS_stat() is a symlink, you are still going to want to know if that symlink is pointing to a directory or a file or other.

So in the case a symlink that points to a file filetype would be set to PHYSFS_FILETYPE_REGULAR|PHYSFS_FILETYPE_SYMLINK.

We could also just make a separate is_symlink field in the PHYSFS_Stat structure and remove PHYSFS_FILETYPE_SYMLINK.

Best regards,
 Indy Sams
 mailto:indy at driftsolutions.com



More information about the physfs mailing list