On Wed, Oct 06, 2010 at 05:08:04AM -0500, Jonathan Nieder wrote: > open() succeeds, though read() fails later, when a pathname > passed as argv[0] on the command line points to a directory, > which somehow results in dash thinking everything is okay: > > $ sh dir/ > $ echo $? > 0 > > But POSIX makes it clear enough that in "sh command_file", > command_file is supposed to be a file, not a directory. So > diagnose this with an error message and exit with status 2. > > Reported-by: Jari Aalto <jari.aalto@xxxxxxxxx> > Fixes: http://bugs.debian.org/548687 > Signed-off-by: Jonathan Nieder <jrnieder@xxxxxxxxx> Is this required by POSIX? If not this is simply making dash bigger for no good reason. Thanks, -- Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt -- To unsubscribe from this list: send the line "unsubscribe dash" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html