Author: jannis
Date: 2007-10-20 19:44:48 +0000 (Sat, 20 Oct 2007)
New Revision: 26161

Modified:
   libxfce4menu/trunk/libxfce4menu/xfce-menu-monitor.c
Log:
        * libxfce4menu/xfce-menu-monitor.c: Add vtable != NULL check
          to xfce_menu_monitor_set_vtable. Avoids crashes when passing
          a NULL pointer and makes other developers aware of what they
          might be doing wrong.
        * STATUS: Updated the status file to reflect the
          current implementation status.

Modified: libxfce4menu/trunk/libxfce4menu/xfce-menu-monitor.c
===================================================================
--- libxfce4menu/trunk/libxfce4menu/xfce-menu-monitor.c 2007-10-20 19:29:21 UTC 
(rev 26160)
+++ libxfce4menu/trunk/libxfce4menu/xfce-menu-monitor.c 2007-10-20 19:44:48 UTC 
(rev 26161)
@@ -96,6 +96,8 @@
 xfce_menu_monitor_set_vtable (XfceMenuMonitorVTable *vtable,
                               gpointer               user_data)
 {
+  g_return_if_fail (vtable != NULL);
+
   if (G_LIKELY (!xfce_menu_monitor_vtable_set))
     {
       if (G_UNLIKELY (vtable->monitor_file && vtable->monitor_directory && 
vtable->remove_monitor))

_______________________________________________
Xfce4-commits mailing list
[email protected]
http://foo-projects.org/mailman/listinfo/xfce4-commits

Reply via email to