shell, panel-list: Avoid accessing a negative array index
As the list of panels doesn't match the list of items in the model.
This commit is contained in:
parent
6127c08fa3
commit
08644a7402
1 changed files with 1 additions and 1 deletions
|
@ -487,7 +487,7 @@ header_func (GtkListBoxRow *row,
|
|||
return;
|
||||
|
||||
pid = get_panel_id_index (get_panel_id_from_row (user_data, row));
|
||||
if (g_str_equal (panel_order[pid-1], "separator"))
|
||||
if (pid > 0 && g_str_equal (panel_order[pid-1], "separator"))
|
||||
{
|
||||
GtkWidget *separator;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue