[PATCH] tin crashes while in reconnection prompt at page level

Dennis Preiser <[email protected]> Thu, 31 Dec 2009 22:57:45 +0100
Newsgroups gmane.network.tin.devel
Message-ID <[email protected]>
Receiving SIGWINCH at page level after the connection timed out and one
sees the reconnection promt leads to a crash. signal.c:handle_resize()
calls (for signal_context == cPage) resize_article(), but load_article()
has called art_close() before art_open() (which lead to the reconnection
prompt).

At selection level, tin doesn't crash after receiving SIGWINCH while
seeing the reconnection prompt, but you see only a blank screen whith the
reconnection promt after resizing.

group level is not affected and thread level behaves ok.

Attached patch changes the behavior as follows:

After receiving SIGWINCH, while seeing the reconnection prompt, tin
presents a blank screen with title $PROGNAME and the reconnection prompt
at the bottom of the screen.

This is a hack to equals the behavior between the different levels and
avoids the crash. I'm not sure whether it's worth to display the
previous screen content after SIGWINCH in that cases (at least at page
level this would not be easy).

Dennis
20091231.diff.gz (application/x-gunzip, 1019 B) - not displayed