rm/unlink and `how to find out who i am'
Devon H. O'Dell
dodell at offmyserver.com
Sat Apr 2 06:12:31 PST 2005
I dunno if there are other files that are hard linked together
and how these are all testing what name they were called by, but
Liam pointed out the case of rm(1) to me today and asked why it
was going about that like it was.
I also don't get it.
To me, it seems that something like:
if (strncmp("unlink", basename(*argv)) == 0)
would make more sense than how it's doing it now (with a
temporary pointer to const char and strrchr). I know that
basename(3) isn't POSIX -- is this an issue?
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 187 bytes
Desc: "Description: PGP signature"
More information about the Kernel