summaryrefslogtreecommitdiff
path: root/tests/test-rollsum-cli.c
diff options
context:
space:
mode:
authorLuca BRUNO <luca.bruno@coreos.com>2022-01-10 10:22:28 +0000
committerLuca BRUNO <luca.bruno@coreos.com>2022-01-10 13:33:36 +0000
commit0bdba574d735ae37447d4c1e8bd0b6a4e622da79 (patch)
tree197674a5e932e37afe0b11b95575570de3a688af /tests/test-rollsum-cli.c
parent92025018f6c64b608ef7f8d8fab27dc18ee90c7f (diff)
downloadostree-0bdba574d735ae37447d4c1e8bd0b6a4e622da79.tar.gz
ostree: check g_setenv return value
This adds proper return-value checks on g_setenv calls. It fixes a static analysis warning highlighted by Coverity.
Diffstat (limited to 'tests/test-rollsum-cli.c')
-rw-r--r--tests/test-rollsum-cli.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/test-rollsum-cli.c b/tests/test-rollsum-cli.c
index 44e3390c..2cf730d3 100644
--- a/tests/test-rollsum-cli.c
+++ b/tests/test-rollsum-cli.c
@@ -35,7 +35,8 @@ main (int argc, char **argv)
OstreeRollsumMatches *matches;
GMappedFile *mfile;
- g_setenv ("GIO_USE_VFS", "local", TRUE);
+ gboolean is_ok = g_setenv ("GIO_USE_VFS", "local", TRUE);
+ g_assert (is_ok == TRUE);
if (argc < 3)
return 1;