summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorRyan Lortie <desrt@desrt.ca>2012-07-06 16:37:47 -0400
committerRyan Lortie <desrt@desrt.ca>2012-07-06 16:37:47 -0400
commita20d8fa3133eadf11a3db9d9ad1761e02bb20d41 (patch)
tree176b8793d2604eace09333a2f9de9a10baf37206 /common
parentd83db37547286b2234022492d2580f9463ae81cc (diff)
downloaddconf-a20d8fa3133eadf11a3db9d9ad1761e02bb20d41.tar.gz
dconf_changeset_get: allow NULL value out argument
We may be interested in only checking the return value for if a key exists or not.
Diffstat (limited to 'common')
-rw-r--r--common/dconf-changeset.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/common/dconf-changeset.c b/common/dconf-changeset.c
index 481a82e..261d4ff 100644
--- a/common/dconf-changeset.c
+++ b/common/dconf-changeset.c
@@ -141,7 +141,9 @@ dconf_changeset_get (DConfChangeset *change,
if (!g_hash_table_lookup_extended (change->table, key, NULL, &tmp))
return FALSE;
- *value = tmp ? g_variant_ref (tmp) : NULL;
+ if (value)
+ *value = tmp ? g_variant_ref (tmp) : NULL;
+
return TRUE;
}