mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-11-13 06:50:54 +01:00
IO (Linux): fixes a possible fd leak
This commit is contained in:
1 parent
1942dce980
commit
470e3b4e57
1 file changed
+1
@@ -259,6 +259,7 @@ void listFilesRecursively(uint32_t baseLength, FFstrbuf* folder, uint8_t indenta
|
||||
|
||||
FF_AUTO_CLOSE_DIR DIR* dir = fdopendir(dfd);
|
||||
if (dir == NULL) {
|
||||
close(dfd);
|
||||
return; // Should not happen
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user