diff options
author | Colin Walters <walters@verbum.org> | 2021-10-08 08:59:52 -0400 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2021-10-13 17:13:14 -0400 |
commit | 3159e04980e567a918e532e168dea89112922460 (patch) | |
tree | 8e3570b8115672099cd5a19af115dc9aa6a739aa /src/libostree | |
parent | 520b45afdd97cab47d55aecab1407a857a7008df (diff) | |
download | ostree-3159e04980e567a918e532e168dea89112922460.tar.gz |
fetcher/soup: Fix gcc `-fanalyzer` warning
In general, we're probably going to need to change most of our
`g_return_if_fail` to `g_assert`. The analyzer flags that
the function can return `NULL`, but the caller isn't prepared for
this.
In practice, let's abort.
Diffstat (limited to 'src/libostree')
-rw-r--r-- | src/libostree/ostree-fetcher-soup.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libostree/ostree-fetcher-soup.c b/src/libostree/ostree-fetcher-soup.c index 5f707175..7df48482 100644 --- a/src/libostree/ostree-fetcher-soup.c +++ b/src/libostree/ostree-fetcher-soup.c @@ -183,7 +183,7 @@ static OstreeFetcherPendingURI * pending_uri_ref (OstreeFetcherPendingURI *pending) { gint refcount; - g_return_val_if_fail (pending != NULL, NULL); + g_assert (pending); refcount = g_atomic_int_add (&pending->ref_count, 1); g_assert (refcount > 0); return pending; |