Commit 0ef43ba7 authored by Allison Karlitskaya's avatar Allison Karlitskaya

GSettingsSchema: store a backref to the source

Record in each GSettingsSchema object the source from which it came.

This will be useful in future commits.
parent e462eda3
......@@ -138,6 +138,7 @@
struct _GSettingsSchema
GSettingsSchemaSource *source;
const gchar *gettext_domain;
const gchar *path;
GQuark *items;
......@@ -412,6 +413,7 @@ g_settings_schema_source_lookup (GSettingsSchemaSource *source,
return NULL;
schema = g_slice_new0 (GSettingsSchema);
schema->source = g_settings_schema_source_ref (source);
schema->ref_count = 1;
schema->id = g_strdup (schema_id);
schema->table = table;
......@@ -588,6 +590,7 @@ g_settings_schema_unref (GSettingsSchema *schema)
if (g_atomic_int_dec_and_test (&schema->ref_count))
g_settings_schema_source_unref (schema->source);
gvdb_table_unref (schema->table);
g_free (schema->items);
g_free (schema->id);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment