pull_with_options: Don't leak csum_v
authorAlexander Larsson <alexl@redhat.com>
Mon, 28 Nov 2016 14:56:50 +0000 (15:56 +0100)
committerSimon McVittie <smcv@debian.org>
Thu, 1 Dec 2016 12:38:54 +0000 (12:38 +0000)
Closes: #596
Approved by: cgwalters
Origin: upstream, 2016.15, commit:239cb14

Gbp-Pq: Name pull_with_options-Don-t-leak-csum_v.patch

src/libostree/ostree-repo-pull.c

index 6f32c77b8c874b9c85c175d6de857b239e5fe594..303daec49eda699c30cf347a0c671f9ca7dc1284 100644 (file)
@@ -2800,7 +2800,7 @@ ostree_repo_pull_with_options (OstreeRepo             *self,
         for (i = 0; i < n; i++)
           {
             const char *delta;
-            GVariant *csum_v = NULL;
+            g_autoptr(GVariant) csum_v = NULL;
             guchar *csum_data = g_malloc (OSTREE_SHA256_DIGEST_LEN);
             g_autoptr(GVariant) ref = g_variant_get_child_value (deltas, i);