[gtk+] Fix a few warnings



commit ca493cd20df9f6a120f950fb254077f8259d5d39
Author: Matthias Clasen <mclasen redhat com>
Date:   Thu Dec 23 22:11:50 2010 -0500

    Fix a few warnings

 gtk/gtkmenushell.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gtk/gtkmenushell.c b/gtk/gtkmenushell.c
index d72670a..71c25d9 100644
--- a/gtk/gtkmenushell.c
+++ b/gtk/gtkmenushell.c
@@ -1883,7 +1883,7 @@ gtk_menu_shell_set_take_focus (GtkMenuShell *menu_shell,
 GtkWidget *
 gtk_menu_shell_get_selected_item (GtkMenuShell *menu_shell)
 {
-  g_return_if_fail (GTK_IS_MENU_SHELL (menu_shell));
+  g_return_val_if_fail (GTK_IS_MENU_SHELL (menu_shell), NULL);
 
   return menu_shell->priv->active_menu_item;
 }
@@ -1904,7 +1904,7 @@ gtk_menu_shell_get_selected_item (GtkMenuShell *menu_shell)
 GtkWidget *
 gtk_menu_shell_get_parent_shell (GtkMenuShell *menu_shell)
 {
-  g_return_if_fail (GTK_IS_MENU_SHELL (menu_shell));
+  g_return_val_if_fail (GTK_IS_MENU_SHELL (menu_shell), NULL);
 
   return menu_shell->priv->parent_menu_shell;
 }



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]