> No way to hand echo or /bin/echo a NULL.
You mean NUL, not NULL. And printf can do it.
> $ set a $'\x00' b
> $ echo $#
> 3
> $ echo A$'\x01'B|wc -c
> 4
> $ echo A$'\x00'B|wc -c
> 3
Here, command substitutions strip all NULs from the command's
output. POSIX doesn't specify whether this behavi
Dan Jacobson <[EMAIL PROTECTED]> wrote:
> No way to hand echo or /bin/echo a NULL.
For /bin/echo, that's because execve() uses null-terminated strings.
For bash's builtin echo, it could be done, but then it would be
inconsistent with external commands, which might be surprising.
paul
_