Check argument to avoid crash
authorPeng Huang <shawn.p.huang@gmail.com>
Fri, 15 Jan 2010 06:55:25 +0000 (14:55 +0800)
committerPeng Huang <shawn.p.huang@gmail.com>
Fri, 15 Jan 2010 06:55:25 +0000 (14:55 +0800)
gconf/config.c

index f03d368a201be2399a3f8be7fe568a63dfb72847..b3662fe80cb9759f42372cf0b63ce9f9f57988bb 100644 (file)
@@ -80,6 +80,9 @@ _value_changed_cb (GConfClient     *client,
     gchar *p, *section, *name;
     GValue v =  { 0 };
 
+    g_return_if_fail (key != NULL);
+    g_return_if_fail (value != NULL);
+
     p = g_strdup (key);
     section = p + sizeof (GCONF_PREFIX);
     name = rindex (p, '/') + 1;