summaryrefslogtreecommitdiff
path: root/common/flatpak-dir.c
diff options
context:
space:
mode:
authorAlexander Larsson <alexl@redhat.com>2018-02-14 10:29:48 +0100
committerAlexander Larsson <alexl@redhat.com>2018-02-14 10:29:48 +0100
commit1fe1337beaee53e43dbf12b009fe11c04851c061 (patch)
tree15abc2ea9eb51dc6c1061d7be68df0e411420676 /common/flatpak-dir.c
parentf33fac310c913c279d59e1a7a6228643097feddc (diff)
downloadflatpak-1fe1337beaee53e43dbf12b009fe11c04851c061.tar.gz
Silence coverity (CID 1465243)
Check the return value of repo_get_remote_collection_id like we do in other places. This doesn't really affect the result, because we return NULL both before and after in the failure case, but it makes things clearer.
Diffstat (limited to 'common/flatpak-dir.c')
-rw-r--r--common/flatpak-dir.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/common/flatpak-dir.c b/common/flatpak-dir.c
index 0195a6dc..dd1ec3a4 100644
--- a/common/flatpak-dir.c
+++ b/common/flatpak-dir.c
@@ -8668,7 +8668,8 @@ flatpak_dir_get_remote_collection_id (FlatpakDir *self,
{
g_autofree char *collection_id = NULL;
- repo_get_remote_collection_id (self->repo, remote_name, &collection_id, NULL);
+ if (!repo_get_remote_collection_id (self->repo, remote_name, &collection_id, NULL))
+ return NULL;
return g_steal_pointer (&collection_id);
}