So long as you're not running with root permissions the underlying unlink(2) should fail with EPERM (per POSIX) if you try and unlink a directory.
$ perl -le 'mkdir "OHNOEZ"; unlink "OHNOEZ" or die "unlink: $!\n";rmdi +r "OHNOEZ"' unlink: Operation not permitted
Your system's rm command's going to be making the same underlying unlink(2) call for the same arguments for that matter; so long as you're not running as root it's a rather spurious thing to worry about.
The cake is a lie.
The cake is a lie.
The cake is a lie.
In reply to Re^3: Need help with loops and 3 tables
by Fletch
in thread Need help with loops and 3 tables
by htmanning
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |