echo: fix handling of \0