diff options
Diffstat (limited to 'shell/ev-navigation-action.c')
-rw-r--r-- | shell/ev-navigation-action.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/shell/ev-navigation-action.c b/shell/ev-navigation-action.c index 9da89f9..3aa1bea 100644 --- a/shell/ev-navigation-action.c +++ b/shell/ev-navigation-action.c @@ -134,12 +134,12 @@ build_menu (EvNavigationAction *action) EvHistory *history = action->priv->history; int start, end, i; - menu = GTK_MENU_SHELL (gtk_menu_new ()); - - if (history == NULL) { - return GTK_WIDGET (menu); + if (history == NULL || ev_history_get_n_links (history) <= 0) { + return NULL; } + menu = GTK_MENU_SHELL (gtk_menu_new ()); + start = 0; end = ev_history_get_n_links (history); |