[Bug 779016] New: 'file' command help text wrongly says it follows symlinks by default
![](https://seccdn.libravatar.org/avatar/3035b38ff33cf86f480bb169b8500b80.jpg?s=120&d=mm&r=g)
https://bugzilla.novell.com/show_bug.cgi?id=779016 https://bugzilla.novell.com/show_bug.cgi?id=779016#c0 Summary: 'file' command help text wrongly says it follows symlinks by default Classification: openSUSE Product: openSUSE 12.1 Version: Final Platform: x86-64 OS/Version: openSUSE 12.1 Status: NEW Severity: Minor Priority: P5 - None Component: Other AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: dan@harthinian.com QAContact: qa-bugs@suse.de Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.89 Safari/537.1 'file --help' shows the following line - -L, --dereference follow symlinks (default) However when using file on a symlink such as /usr/lib64/libpng.so it returns - /usr/lib64/libpng.so: symbolic link to `libpng12.so' The correct output is given by the command 'file -L /usr/lib64/libpng.so' as /usr/lib64/libpng.so: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=0x562321b899ebde788de44da61c1fb730d3508115, stripped -L is not the default as stated in the --help. Reproducible: Always Steps to Reproduce: 1. On the command line - 2. 'file --help' 3. The -L option is listed as the default 4. 'file /usr/lib64/libpng.so' (or any other symlink). Actual Results: /usr/lib64/libpng.so: symbolic link to `libpng12.so' Expected Results: /usr/lib64/libpng.so: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=0x562321b899ebde788de44da61c1fb730d3508115, stripped Not tested if it is an upstream bug. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
![](https://seccdn.libravatar.org/avatar/3035b38ff33cf86f480bb169b8500b80.jpg?s=120&d=mm&r=g)
https://bugzilla.novell.com/show_bug.cgi?id=779016
https://bugzilla.novell.com/show_bug.cgi?id=779016#c
kk zhang
![](https://seccdn.libravatar.org/avatar/3035b38ff33cf86f480bb169b8500b80.jpg?s=120&d=mm&r=g)
https://bugzilla.novell.com/show_bug.cgi?id=779016
https://bugzilla.novell.com/show_bug.cgi?id=779016#c1
Dr. Werner Fink
file ~/core /suse/werner/core: symbolic link to `/dev/null' POSIXLY_CORRECT=1 file ~/core /suse/werner/core: character special
this is how it worksas read in src/file.c [... line 160 ff ...] #ifdef S_IFLNK flags |= getenv("POSIXLY_CORRECT") ? MAGIC_SYMLINK : 0; #endif [...] and I'll not go to change that. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com