summaryrefslogtreecommitdiff
path: root/src/ostree/ot-builtin-refs.c
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2017-07-31 09:30:09 -0400
committerAtomic Bot <atomic-devel@projectatomic.io>2017-08-02 15:34:16 +0000
commit78348fa296dc03c366a08f40aaa90565f5743158 (patch)
tree47259a79eac578b572963c087554104e5d95f667 /src/ostree/ot-builtin-refs.c
parent36ab8cd0e1cf487fe5f03917a617ab88d7b0a86d (diff)
downloadostree-78348fa296dc03c366a08f40aaa90565f5743158.tar.gz
bin/refs: Fix error handling logic
Spotted by Coverity. Coverity CID: 1452202 Closes: #1037 Approved by: jlebon
Diffstat (limited to 'src/ostree/ot-builtin-refs.c')
-rw-r--r--src/ostree/ot-builtin-refs.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ostree/ot-builtin-refs.c b/src/ostree/ot-builtin-refs.c
index 19420842..f2274802 100644
--- a/src/ostree/ot-builtin-refs.c
+++ b/src/ostree/ot-builtin-refs.c
@@ -264,7 +264,8 @@ ostree_builtin_refs (int argc, char **argv, GCancellable *cancellable, GError **
goto out;
}
- ret = do_ref (repo, NULL, cancellable, error);
+ if (!do_ref (repo, NULL, cancellable, error))
+ goto out;
}
ret = TRUE;