If I kill vim (ex. kill -9) key mapping changes and backspace key causes printing of ^? instead of removing of the current character in terminal. 'reset' command doesn't restore this either. so it's no way to restore original setting besides of running the command 'stty erase ^?' Originally 'stty -a' reports: -----------begin------------------------ speed 38400 baud; 42 rows; 189 columns; lflags: icanon isig iexten echo echoe echok echoke -echonl echoctl -echoprt -altwerase -noflsh -tostop -flusho pendin -nokerninfo -extproc iflags: -istrip icrnl -inlcr -igncr ixon -ixoff ixany imaxbel -ignbrk brkint -inpck -ignpar -parmrk oflags: opost onlcr -ocrnl -oxtabs -onocr -onlret cflags: cread cs8 -parenb -parodd hupcl -clocal -cstopb -crtscts -dsrflow -dtrflow -mdmbuf cchars: discard = ^O; dsusp = ^Y; eof = ^D; eol = <undef>; eol2 = <undef>; erase = ^?; erase2 = ^H; intr = ^C; kill = ^U; lnext = ^V; min = 1; quit = ^\; reprint = ^R; start = ^Q; status = ^T; stop = ^S; susp = ^Z; time = 0; werase = ^W; -------------end------------------------ After killing vim and running 'reset' 'stty -a' reports: -----------begin------------------------ speed 38400 baud; 42 rows; 189 columns; lflags: icanon isig iexten echo echoe echok echoke -echonl echoctl -echoprt -altwerase -noflsh -tostop -flusho pendin -nokerninfo -extproc iflags: -istrip icrnl -inlcr -igncr ixon -ixoff -ixany imaxbel -ignbrk brkint -inpck ignpar -parmrk oflags: opost onlcr -ocrnl oxtabs -onocr -onlret cflags: cread cs8 -parenb -parodd hupcl -clocal -cstopb -crtscts -dsrflow -dtrflow -mdmbuf cchars: discard = ^O; dsusp = ^@; eof = ^D; eol = <undef>; eol2 = <undef>; erase = ^H; erase2 = ^H; intr = ^C; kill = ^U; lnext = ^V; min = 1; quit = ^\; reprint = ^R; start = ^Q; status = ^T; stop = ^S; susp = ^Z; time = 0; werase = ^W; -------------end------------------------ because 'erase = ^H' particularly backspace key is disrupted. Fix: N/A How-To-Repeat: see full description
For bugs matching the following criteria: Status: In Progress Changed: (is less than) 2014-06-01 Reset to default assignee and clear in-progress tags. Mail being skipped
Is this really a bug? According to the man page for teset(1), when invoked as reset, tset does several things before initializing the terminal as tset. If the -m option is not passed (as in this case), then tset tries to _guess_ the terminal type that is being used. As I understand there is no guarantee that this guess will be a perfect match for all the terminal options. Additionally, reset -e ^? ensures the correct key binding for the erase character after the initialization has been completed (in the case of the reporter).