mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 23:50:19 +00:00
a10e63f08e
SysFS, ProcFS and DevPtsFS were all sending filetype 0 when traversing their directories, but it is actually very easy to send proper filetypes in these filesystems. This patch binds all RAM backed filesystems to use only one enum for their internal filetype, to simplify the implementation and allow sharing of code. Please note that the Plan9FS case is currently not solved as I am not familiar with this filesystem and its constructs. The ProcFS mostly keeps track of the filetype, and a fix was needed for the /proc root directory - all processes exhibit a directory inside it which makes it very easy to hardcode the directory filetype for them. There's also the `self` symlink inode which is now exposed as DT_LNK. As for SysFS, we could leverage the fact everything inherits from the SysFSComponent class, so we could have a virtual const method to return the proper filetype. Most of the files in SysFS are "regular" files though, so the base class has a non-pure virtual method. Lastly, the DevPtsFS simply hardcodes '.' and '..' as directory file type, and everything else is hardcoded to send the character device file type, as this filesystem is only exposing character pts device files. |
||
---|---|---|
.. | ||
API | ||
Arch | ||
Boot | ||
Bus | ||
Devices | ||
FileSystem | ||
Firmware/ACPI | ||
Heap | ||
Interrupts | ||
Library | ||
Locking | ||
Memory | ||
Net | ||
Prekernel | ||
Security | ||
Syscalls | ||
Tasks | ||
Time | ||
CMakeLists.txt | ||
Debug.h.in | ||
embedmap.sh | ||
Forward.h | ||
generate-version-file.sh | ||
kprintf.cpp | ||
kstdio.h | ||
KSyms.cpp | ||
KSyms.h | ||
mkmap.sh | ||
SanCov.cpp | ||
Sections.h | ||
UnixTypes.h |