On 09/19/2016 11:58 AM, Greg Wooledge wrote: > On Mon, Sep 19, 2016 at 09:28:53AM -0700, L. A. Walsh wrote: >> If users were relying on this behavior (I know I have scripts that read >> things from proc -- a text interface that uses \0 to display values similar >> to MS's multi-string Values in the Windows registry. > >> Could you change it back or provide a way to suppress "kiddy-scripter" >> seatbelts? > > wooledg@wooledg:~$ x=$(< /proc/$$/cmdline) > bash-4.4: warning: command substitution: ignored null byte in input > wooledg@wooledg:~$ x=$(< /proc/$$/cmdline 2>/dev/null) > wooledg@wooledg:~$
Or: $ x=$(< /proc/$$/cmdline tr -d \\0) -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature