Configuration Information [Automatically generated, do not change]: Machine: x86_64 OS: linux-gnu Compiler: gcc Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-unknown-linux-gnu' -DCONF_VENDOR='unknown' -DLOCALEDIR='/usr/local/share/locale' -DPACKAGE='bash' -DSHELL -DHAVE_CONFIG_H -I. -I. -I./include -I./lib -g -O2 uname output: Linux brahma 2.6.38-2-amd64 #1 SMP Sat Apr 23 18:47:49 UTC 2011 x86_64 GNU/Linux Machine Type: x86_64-unknown-linux-gnu
Bash Version: 4.2 Patch Level: 0 Release Status: release Description: The builtin read command does not work like e.g. dash or zsh w.r.t. the null character '\0', however I'm not sure it can be considered as a bug. If a line containing the '\0' is read into a variable, the content of this variable does not contain the part after the '\0' character. Repeat-By: echo -e 'a\0b' | (read f; echo $f) The output is 'a', and '\0b' is stripped.