Fix NUL character introducing escape secuence for octal values

We now use hex escape to inject the NUL character.

NUL characters start escape sequence for inserting a byte given its octal
value. This caused problems when environment variables had digit values. For
example, if the value of the variable SSH_AGENT_PID is "46", the command
`printf "\046"` would result, and the output would be `&`, as 046 is the octal
value for the ampersand character.