From 5def781182f34825eab77800e44a299984dcf17d Mon Sep 17 00:00:00 2001 From: Marc-Antoine Perennou Date: Tue, 3 Dec 2019 16:15:16 +0100 Subject: as-app: properly initialize unique_id_mutex We are using it, clearing it, but e never initialize it. For some reasons it seems to work, not sure how or why, but when glib is uilt with clang, then the problem surfaces and we get a nice segmentation fault. Properly initializing it fixes this Signed-off-by: Marc-Antoine Perennou --- libappstream-glib/as-app.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libappstream-glib/as-app.c b/libappstream-glib/as-app.c index 7bc0bf9..d24b2f0 100644 --- a/libappstream-glib/as-app.c +++ b/libappstream-glib/as-app.c @@ -524,6 +524,7 @@ as_app_init (AsApp *app) priv->urls = g_hash_table_new_full (g_str_hash, g_str_equal, (GDestroyNotify) as_ref_string_unref, (GDestroyNotify) as_ref_string_unref); + g_mutex_init (&priv->unique_id_mutex); priv->token_cache = g_hash_table_new_full (g_str_hash, g_str_equal, (GDestroyNotify) as_ref_string_unref, g_free); -- cgit v1.2.1