that fail - instead of in most of the callers.
All rather pointless if tcsetattr() fails to set the mode we want we
are very unlikely to be able to restore any later on.
are pushed back. Should fix the arrow keys part of PR pkg/37173.
While we are here, make getch() and get_wch() check for resize immediately,
instead of reading a key, checking for resize and then having to push-back
the just read key.