This happens in xfce4 when preferences for sending backspace is set to "autodetect". Not when an explicit value ^H or DELETE is set. Hm... seems likely to be an xfce4 or vte thing, then. Retargetting for xfce4-terminal.
For some annoying reason I can't for the life of me figure out (unless it's somehow related to the use of a second pty), I can't reproduce the problem within the "script" command.
I've been reproducing the problem by running "screen cat" and hitting the backspace a couple times to see if I get ^@.
In response to the bindkey solution: that won't work, since -k kb is ^?. The following works better:
This happens in xfce4 when preferences for sending backspace is set to "autodetect". Not when an explicit value ^H or DELETE is set. Hm... seems likely to be an xfce4 or vte thing, then. Retargetting for xfce4-terminal.
For some annoying reason I can't for the life of me figure out (unless it's somehow related to the use of a second pty), I can't reproduce the problem within the "script" command.
I've been reproducing the problem by running "screen cat" and hitting the backspace a couple times to see if I get ^@.
In response to the bindkey solution: that won't work, since -k kb is ^?. The following works better:
bindkey -d ^@ stuff ^?