mirror of https://github.com/MidnightCommander/mc
Ticket #4323: fix segfault on change panel mode.
How to reproduce: 1. Set left panel to list mode. 2. Make left panel active. 3. Change left panel to info mode. Result: segmentation fault. (widget_replace): fix search of the next focusable widget. Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
parent
d0cc71e48a
commit
13df437ba1
|
@ -573,7 +573,8 @@ widget_replace (Widget * old_w, Widget * new_w)
|
|||
{
|
||||
GList *l;
|
||||
|
||||
for (l = group_get_widget_next_of (holder); widget_is_focusable (WIDGET (l->data));
|
||||
for (l = group_get_widget_next_of (holder);
|
||||
!widget_is_focusable (WIDGET (l->data)) && l != holder;
|
||||
l = group_get_widget_next_of (l))
|
||||
;
|
||||
|
||||
|
|
Loading…
Reference in New Issue