read(1) garbage when input redirected from make incorrectly
Jan Mikkelsen
janm-freebsd-hackers at transactionware.com
Tue Feb 16 23:41:31 UTC 2010
On 16/02/2010, at 10:49 PM, Dag-Erling Smørgrav wrote:
> The LHS of < is a command, the RHS is the name of the file to be read.
> After that, you can have further redirections, a command separator
> (semicolon, single or double ampersand, single or double pipe etc.), or,
> depending on context, various other stuff such as a paren, bracket,
> backquote etc.
A redirection doesn't terminate the argument list.
For example:
echo a b < /dev/null c d
Produces:
a b c d
And:
< /etc/passwd cat
Will emit /etc/passwd to stdout.
Regards,
Jan Mikkelsen
More information about the freebsd-hackers
mailing list