GNU bug report logs -
#60981
Bug in man page for the "test" command
Previous Next
Full log
View this message in rfc822 format
Dear colleagues,
this might have been reported before (or not), but there is a confusing description in the man page of the "test command:
###
-e FILE
FILE exists
-L FILE
FILE exists and is a symbolic link (same as -h)
###
The problem here is the situation of a broken symlink. When flag -e is used on a broken symbolic link, it fails. But when -L is used on a broken symlink, it returns true.
While this may be the expected behavior, it does not reflect what the documentation says. Because if -e fails on a broken symlink ("FILE exists") one would assume that the same of course is true for -L. The correct description for -L should be:
###
-e FILE
FILE exists or is valid symbolic link
-L FILE
FILE is a symbolic link, whether broken or not (same as -h)
###
Kind Regards,
Kaulkwappe
This bug report was last modified 2 years and 205 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.