mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-10-04 20:59:21 +02:00
gvariant-core: Add pre-condition on variant store data being non-null
We define the data not-nullable in docs, but we didn't check this prerequisite programmatically
This commit is contained in:
@@ -1415,6 +1415,8 @@ void
|
|||||||
g_variant_store (GVariant *value,
|
g_variant_store (GVariant *value,
|
||||||
gpointer data)
|
gpointer data)
|
||||||
{
|
{
|
||||||
|
g_return_if_fail (data != NULL);
|
||||||
|
|
||||||
g_variant_lock (value);
|
g_variant_lock (value);
|
||||||
|
|
||||||
if (value->state & STATE_SERIALISED)
|
if (value->state & STATE_SERIALISED)
|
||||||
|
Reference in New Issue
Block a user