[tracker/wip/carlosg/coverity-fixes: 3/7] docs: Avoid dead expression in code example




commit d575d1648afd8b2fa3fd094a88816cc2bde3982d
Author: Carlos Garnacho <carlosg gnome org>
Date:   Mon Sep 7 18:10:49 2020 +0200

    docs: Avoid dead expression in code example
    
    Spotted by Coverity
    
    CID: #1491748

 docs/reference/libtracker-sparql/examples/readonly-example.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/docs/reference/libtracker-sparql/examples/readonly-example.c 
b/docs/reference/libtracker-sparql/examples/readonly-example.c
index 6ede580df..3759e5299 100644
--- a/docs/reference/libtracker-sparql/examples/readonly-example.c
+++ b/docs/reference/libtracker-sparql/examples/readonly-example.c
@@ -25,7 +25,7 @@ int main (int argc, const char **argv)
   if (error) {
     /* Some error happened performing the query, not good */
     g_printerr ("Couldn't query the Tracker Store: '%s'",
-                error ? error->message : "unknown error");
+                error->message);
     g_clear_error (&error);
 
     return 1;


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