[tracker-miners/wip/carlosg/coverity-fixes: 10/11] tests: Check g_remove() call return value




commit 51be916ba0736a788fb60826e6485f0fdc388961
Author: Carlos Garnacho <carlosg gnome org>
Date:   Mon Sep 7 19:04:32 2020 +0200

    tests: Check g_remove() call return value
    
    Spotted by Coverity
    
    CID: #162188

 tests/libtracker-miners-common/tracker-file-utils-test.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/tests/libtracker-miners-common/tracker-file-utils-test.c 
b/tests/libtracker-miners-common/tracker-file-utils-test.c
index 1aebf0ba7..6a011ccd3 100644
--- a/tests/libtracker-miners-common/tracker-file-utils-test.c
+++ b/tests/libtracker-miners-common/tracker-file-utils-test.c
@@ -399,7 +399,7 @@ test_file_exists_and_writable ()
         /* Doesn't exist and cannot be created */
         g_assert_true (!tracker_path_has_write_access_or_was_created ("/var/log/tracker-test"));
 
-        g_remove (path);
+        g_assert_cmpint (g_remove (path), ==, 0);
 }
 
 static void


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]