mirror of
https://github.com/irssi/irssi.git
synced 2026-08-20 00:52:30 +02:00
Revert "Merge pull request #452 from LemonBoy/terminfo-cup"
Fixes #733. The fix outlined in #452 had adverse effects for the following reason. The code removed the restoration path that would go on the code path from kill SIGTSTP. The problem is this: When Irssi is not running in a controlling parent (like a shell), the TSTP will in fact be ignored. In that case, there is no process sending a CONT either and thus the screen state never gets restored. Luckily, the patch in #457 is sufficient to prevent the problem in #450 (which lead to the development of #452). To that end, we do end up with potentially calling terminfo_cont twice but that is better than not calling it at all. This reverts commitb1ffd5f647, reversing changes made to9cb0419435.
This commit is contained in:
parent
663a8e7154
commit
947682e5dd
1 changed files with 7 additions and 0 deletions
|
|
@ -629,6 +629,13 @@ void term_stop(void)
|
||||||
{
|
{
|
||||||
terminfo_stop(current_term);
|
terminfo_stop(current_term);
|
||||||
kill(getpid(), SIGTSTP);
|
kill(getpid(), SIGTSTP);
|
||||||
|
/* this call needs to stay here in case the TSTP was ignored,
|
||||||
|
because then we never see a CONT to call the restoration
|
||||||
|
code. On the other hand we also cannot remove the CONT
|
||||||
|
handler because then nothing would restore the screen when
|
||||||
|
Irssi is killed with TSTP/STOP from external. */
|
||||||
|
terminfo_cont(current_term);
|
||||||
|
irssi_redraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
static int input_utf8(const unsigned char *buffer, int size, unichar *result)
|
static int input_utf8(const unsigned char *buffer, int size, unichar *result)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue