Return ENOEXEC, not ENOENT, if a binary's or script's interpreter doesn't exist.
Quoted 2 lines
NAK. Current behaviour is useful -- and it is really file thats missing.
The current behavior is only useful to people who have an understanding of how interpreters and binaries work on Linux. The average desktop user does not have that understanding. The average user gets an error message such as:
/usr/bin/foo: No such file or directory.
They then go and look at /usr/bin/foo, find that it exists, and are extremely confused.
More advanced users might at that point try and run "ldd" on the binary (which will also fail, thanks to a missing interpreter). The average user will never think to run "strings" on the binary and look for /lib/ld-linux.so.1.
Quoted 1 line
Please improve manpage instead.
What manpage do you suggest needs improvement? execve(2)? That again requires an average user to realize that they need to go look at the execve(2) manpage. The average user is not going to realize that.
-Jon
---
Jonathan Reed
[email protected]
Faculty and Student Experience
Information Services & Technology
Massachusetts Institute of Technology
Quoted 2 lines
They then go and look at
/usr/bin/foo, find that it exists, and are extremely confused.
-ENOEXEC is just as confusing. It is executable, it will match (cmp/md5sum etc) with one on another box etc.
Quoted 2 lines
More advanced users might at that point try and run "ldd" on the binary (which will also fail, thanks to a missing interpreter).
So fix ldd ?
Quoted 6 lines · Jonathan Reed
Quoted 2 lines
NAK. Current behaviour is useful -- and it is really file thats missing.
The current behavior is only useful to people who have an understanding of how interpreters and binaries work on Linux. The average desktop user
Proposed behaviour is useless to everyone.
Quoted 7 lines
does not have that understanding. The average user gets an error message such as:
/usr/bin/foo: No such file or directory.They then go and look at
/usr/bin/foo, find that it exists, and are extremely confused.
ENOEXEC is confusing, too. It will have x bit.
Quoted 4 lines
Quoted 1 line
Please improve manpage instead.
What manpage do you suggest needs improvement? execve(2)? That again
execve, I'd say.
Quoted 2 lines
requires an average user to realize that they need to go look at the execve(2) manpage. The average user is not going to realize that.
Improve shells to provide more helpful error message?
Pavel
Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html