diff options
Diffstat (limited to 'docs/reference/libtracker-sparql/examples/writeonly-example.c')
-rw-r--r-- | docs/reference/libtracker-sparql/examples/writeonly-example.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/docs/reference/libtracker-sparql/examples/writeonly-example.c b/docs/reference/libtracker-sparql/examples/writeonly-example.c index ed7fc0084..94104c3d7 100644 --- a/docs/reference/libtracker-sparql/examples/writeonly-example.c +++ b/docs/reference/libtracker-sparql/examples/writeonly-example.c @@ -17,9 +17,9 @@ int main (int argc, const char **argv) "}"; connection = tracker_sparql_connection_bus_new ("org.freedesktop.Tracker3.Miner.Files", NULL, NULL, &error); - if (!connection) { + if (!error) { g_printerr ("Couldn't obtain a connection to the Tracker store: %s", - error ? error->message : "unknown error"); + error->message); g_clear_error (&error); return 1; @@ -33,7 +33,7 @@ int main (int argc, const char **argv) if (error) { /* Some error happened performing the query, not good */ g_printerr ("Couldn't update the Tracker store: %s", - error ? error->message : "unknown error"); + error->message); g_clear_error (&error); g_object_unref (connection); |