> The realisation that a shutdown communication may contain \0 (since NUL is a > valid UTF-8 char), led me to alter the proposed changes. A debugging tool like > tcpdump should display trash too. This 0003 patch avoids the memset/memcpy and > can deal with trash in the shutdown communication through a new util > putlchars().
What kind of trash do you mean? Any kind of trash? How about an xterm set-title ANSI sequence, or something worse. Personally, I think this should use vis.