mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-22 12:32:40 +03:00
Merge branch '2966_view_broken_manpage_fix'
* 2966_view_broken_manpage_fix: Ticket #2966: mcview: fix segfault after switch from parse to raw mode and back.
This commit is contained in:
commit
774762a8e9
@ -210,7 +210,15 @@ mcview_growbuf_read_until (mcview_t * view, off_t ofs)
|
||||
g_free (err_msg);
|
||||
}
|
||||
|
||||
mcview_growbuf_done (view);
|
||||
if (view->ds_stdio_pipe != NULL)
|
||||
{
|
||||
/* when switch from parse to raw mode and back,
|
||||
* do not close the already closed pipe after following loop:
|
||||
* mcview_growbuf_read_until() -> mcview_show_error() ->
|
||||
* MSG_DRAW -> mcview_display() -> mcview_get_byte() -> mcview_growbuf_read_until()
|
||||
*/
|
||||
mcview_growbuf_done (view);
|
||||
}
|
||||
mcview_display (view);
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user