News for hackers. Stuff that matters.
Re:Byenow – A command-line Windows utility for faster folder... by jjnoakes on Thursday February 20, 2020 @10:52AM (#22375894)
unlink(2) returns EISDIR (on Linux at least) if you try to unlink a directory. I'm not sure if you can still do it, but long ago you could unlink(2) a directory as root, but it was not a good idea since it did not recursively free up the contents back to the file system's raw storage.

To remove a directory on Linux you have to empty it out (recursively, using unlink(2) on files and rmdir(2) on empty directories) and then rmdir(2) the top level directory.

So not a single system call.

Re:Byenow – A command-line Windows utility for faster folder... by pbhjpbhj on Saturday February 22, 2020 @10:08AM (#22391358)
Thanks for humouring me, everyday a learning day - especially when there are kind people happy to share their knowledge ;o)