[ast-developers] [BUG] 'command -p' broken in certain contexts
Martijn Dekker
2017-02-26 16:35:18 UTC
'command -p' is supposed to run a command with the default system PATH
as opposed to the current $PATH, so it is guaranteed to get a POSIX
standard utility. But:

$ ksh -c 'command -p ls'
ksh: ls: not found
$ ksh -c '(command -p ls)'
ksh: ls: not found
$ ksh -c 'echo $(command -p ls)'
(file listing is output)
$ ksh -c 'command -p ls & wait'
(file listing is output)

Bug confirmed on:
Version JM 93t+ 2010-03-05
Version AJM 93u+ 2012-08-01

Bug *not* present on:
Version M 1993-12-28 r

- M.