aboutsummaryrefslogtreecommitdiff
path: root/libdbusmenu-glib
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2011-09-27 11:04:01 -0500
committerTed Gould <ted@gould.cx>2011-09-27 11:04:01 -0500
commit031ff0b4400551f272f876ed2eb63a4f0c2a3a49 (patch)
tree69bc7b8eb2af69d3f501ca9b729925b37c7f1de8 /libdbusmenu-glib
parent201093de1febf37f60d27dea220fe24ed4cd05b0 (diff)
parentbe4dca14aedcd3fc3482e593d1bcce69fe53d0bd (diff)
downloadlibdbusmenu-031ff0b4400551f272f876ed2eb63a4f0c2a3a49.tar.gz
libdbusmenu-031ff0b4400551f272f876ed2eb63a4f0c2a3a49.tar.bz2
libdbusmenu-031ff0b4400551f272f876ed2eb63a4f0c2a3a49.zip
Protect from a NULL class
Diffstat (limited to 'libdbusmenu-glib')
-rw-r--r--libdbusmenu-glib/menuitem.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libdbusmenu-glib/menuitem.c b/libdbusmenu-glib/menuitem.c
index 4e037ee..c9c7736 100644
--- a/libdbusmenu-glib/menuitem.c
+++ b/libdbusmenu-glib/menuitem.c
@@ -1730,7 +1730,7 @@ dbusmenu_menuitem_send_about_to_show (DbusmenuMenuitem * mi, void (*cb) (Dbusmen
#endif
DbusmenuMenuitemClass * class = DBUSMENU_MENUITEM_GET_CLASS(mi);
- if (class->send_about_to_show != NULL) {
+ if (class != NULL && class->send_about_to_show != NULL) {
return class->send_about_to_show(mi, cb, cb_data);
} else if (cb != NULL) {
cb(mi, cb_data);