02:58 <+bridge> [ddnet] @ChillerDragon should be a one line fix 16:32 <+bridge> [ddnet] Does Storage()->RemoveFile(...) work with folders? 16:32 <+bridge> [ddnet] I would say no but im not sure 16:39 <+bridge> [ddnet] yes 16:40 <+bridge> [ddnet] we use the `remove` function from POSIX standard, so see `man 3p remove` 16:40 <+bridge> [ddnet] files and folder on linux are the same right 16:40 <+bridge> [ddnet] > If path does not name a directory, remove(path) shall be equivalent to unlink(path). 16:40 <+bridge> [ddnet] > If path names a directory, remove(path) shall be equivalent to rmdir(path). 16:40 <+bridge> [ddnet] So only empty directories will be deleted, not recursively. 16:41 <+bridge> [ddnet] hm 16:41 <+bridge> [ddnet] ok thx 16:42 <+bridge> [ddnet] @Ryozuki not exactly. unlink() on a directory is not guaranteed to work by POSIX 16:59 <+bridge> [ddnet] hmm 16:59 <+bridge> [ddnet] it didn't delete an empty directory 17:19 <+bridge> [ddnet] this should work if the tmp directory is empty right? 17:19 <+bridge> [ddnet] 17:19 <+bridge> [ddnet] https://cdn.discordapp.com/attachments/293493549758939136/613391656875589642/unknown.png 18:28 <+bridge> [ddnet] @archimede67 true, i can reproduce. 18:30 <+bridge> [ddnet] actually no, works for me 18:30 <+bridge> [ddnet] i just accidentally did it twice and then the second one fails of course 18:31 <+bridge> [ddnet] Windows might not implement remove C99-compliantly 18:32 <+bridge> [ddnet] Yep: https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/remove-wremove?view=vs-2019 18:32 <+bridge> [ddnet] > EACCES to indicate that the path specifies a read-only file, specifies a directory 18:33 <+bridge> [ddnet] Feel free to add a RemoveDirectory function 18:35 <+bridge> [ddnet] sorry, actually C89/99 only define that remove can remove files, no mention of directories 21:03 <+bridge> [ddnet] and while you're at it, use unlink directly so that RemoveFile only removes files, not dirs 21:06 <+bridge> [ddnet] so i should use remove in RemoveDirectory and unlink in RemoveFile? 23:17 <@deen> rmdir in RemoveDirectory 23:18 <+bridge> [ddnet] ah yes thank you 23:53 <+bridge> [ddnet] lol i'm actually dumb