Indeed, this behavior is certainly wrong and is in violation of the
POSIX standard.

http://pubs.opengroup.org/onlinepubs/009696899/utilities/command.html

"-v
(On systems supporting the User Portability Utilities option.) Write a
string to standard output that indicates **the pathname or command
that will be used by the shell**, in the current shell execution
environment (see Shell Execution Environment ), to invoke
command_name, but do not invoke command_name."

(Emphasis mine).

The non-executable file will NOT be used either with direct execution
or when executing with "command" without -v.

Reply via email to