23.15 Using unlink to Remove a File with a Strange Name
Some versions of UNIX have a lot of trouble with eight-bit filenames - that
is, filenames that contain non-
command shows the non-ASCII characters as question
If you can move all the other files out of the directory, then you'll probably be able to remove the leftover file and directory with rm -rf (23.17 , 23.10 ) . Moving files and removing the directory is a bad idea, though, if this is an important system directory like /bin .
Otherwise, if you can find the filename in the od
listing of the
directory (it will probably end with a series of NUL characters,
perl -e 'unlink("\t\360\207\005\254");'
If you don't have Perl, write a little C program (52.8 ) :
Another ls will tell you whether your program worked (there probably won't be any error messages if it doesn't work).