From c533e1aee6e92b82625dda50dd042e6122e7d1f0 Mon Sep 17 00:00:00 2001 From: Sam Spilsbury Date: Wed, 1 Jun 2016 05:59:54 +0000 Subject: [PATCH] summary: Make flatpak_cache_dir_summary static void This function always returned NULL, and the return value was never checked. --- common/flatpak-dir.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/common/flatpak-dir.c b/common/flatpak-dir.c index d68e5400..781be2a7 100644 --- a/common/flatpak-dir.c +++ b/common/flatpak-dir.c @@ -3738,18 +3738,17 @@ flatpak_dir_lookup_cached_summary (FlatpakDir *self, return res; } -static GBytes * +static void flatpak_dir_cache_summary (FlatpakDir *self, GBytes *bytes, const char *name, const char *url) { CachedSummary *summary; - GBytes *res = NULL; /* No sense caching the summary if there isn't one */ if (!bytes) - return NULL; + return; G_LOCK (cache); @@ -3760,8 +3759,6 @@ flatpak_dir_cache_summary (FlatpakDir *self, g_hash_table_insert (self->summary_cache, summary->remote, summary); G_UNLOCK (cache); - - return res; } static gboolean