shfm
shfm copied to clipboard
fixed bug that overwrites saved stty settings
To reproduce the bug, start shfm, resize your terminal to trigger SIGWINCH's trap, then exit shfm. You'll notice that icanon and echo are disabled even though term_reset should've reset those. At program start, stty is saved so that it can be restored at exit. SIGWINCH's trap calls term_setup which overwrites stty unnecessarily. I moved stty set out of term_setup to avoid this.