From 340144265f38e9b186f6f89b6ad46a5640f62f2f Mon Sep 17 00:00:00 2001 From: Colin Walters Date: Sun, 12 Mar 2017 20:56:28 -0400 Subject: [PATCH] pull: Squash a `-Wmaybe-uninitialized` warning Tempting to make it fatal...but we'd have to basically init all of our variables I think. Closes: #734 Approved by: jlebon --- src/libostree/ostree-repo-pull.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libostree/ostree-repo-pull.c b/src/libostree/ostree-repo-pull.c index 5ee43918..ec085a81 100644 --- a/src/libostree/ostree-repo-pull.c +++ b/src/libostree/ostree-repo-pull.c @@ -1882,7 +1882,7 @@ get_best_static_delta_start_for (OtPullData *pull_data, /* Array of possible from checksums */ g_autoptr(GPtrArray) candidates = g_ptr_array_new_with_free_func (g_free); const char *newest_candidate = NULL; - guint64 newest_candidate_timestamp; + guint64 newest_candidate_timestamp = 0; g_assert (pull_data->summary_deltas_checksums != NULL); g_hash_table_iter_init (&hiter, pull_data->summary_deltas_checksums); @@ -1911,7 +1911,7 @@ get_best_static_delta_start_for (OtPullData *pull_data, for (guint i = 0; i < candidates->len; i++) { const char *candidate = candidates->pdata[i]; - guint64 candidate_ts; + guint64 candidate_ts = 0; g_autoptr(GVariant) commit = NULL; OstreeRepoCommitState state; gboolean have_candidate;