summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2023-03-23 11:26:12 +0000
committerAlexander Larsson <alexander.larsson@gmail.com>2023-03-30 14:42:44 +0200
commitcffc3aed5b9034e9b74ae60daba452ceb97ac9cc (patch)
tree698061cd3d6c1353885ba07832332fee3d541bb5
parent23ec4eda2f52e1570e2296061f9fd4763d7e3721 (diff)
downloadflatpak-cffc3aed5b9034e9b74ae60daba452ceb97ac9cc.tar.gz
testlibrary: Initialize autofree variable to silence a compiler warning
As with commit 43085c0e "dir: Consistently initialize g_autofree variables", this is currently harmless because we never actually early-return or goto out of the region between declaration and initialization, but some compiler versions log a warning here anyway. Signed-off-by: Simon McVittie <smcv@collabora.com>
-rw-r--r--tests/testlibrary.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/testlibrary.c b/tests/testlibrary.c
index 84857f9d..3b3530dd 100644
--- a/tests/testlibrary.c
+++ b/tests/testlibrary.c
@@ -207,7 +207,7 @@ test_installation_config (void)
g_autofree char *path = NULL;
g_autoptr(GFile) file = NULL;
g_autoptr(GError) error = NULL;
- g_autofree char *value;
+ g_autofree char *value = NULL;
gboolean res;
guint64 bytes;