[tracker] tracker-extract: Silence Coverity warning
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker] tracker-extract: Silence Coverity warning
- Date: Wed, 14 Dec 2016 19:44:27 +0000 (UTC)
commit 5dfe675f32014dd30ca3cbbda943e97741c95283
Author: Carlos Garnacho <carlosg gnome org>
Date: Wed Dec 14 19:57:51 2016 +0100
tracker-extract: Silence Coverity warning
The return value of g_file_load_contents() is not used. We checked
the returned error instead so the code is equivalent, but directly
checking the return value seems more readable.
src/tracker-extract/tracker-cue-sheet.c | 4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
---
diff --git a/src/tracker-extract/tracker-cue-sheet.c b/src/tracker-extract/tracker-cue-sheet.c
index 5e1b650..39722d9 100644
--- a/src/tracker-extract/tracker-cue-sheet.c
+++ b/src/tracker-extract/tracker-cue-sheet.c
@@ -380,9 +380,7 @@ tracker_cue_sheet_parse_uri (const gchar *uri)
cue_sheet_file = n->data;
- g_file_load_contents (cue_sheet_file, NULL, &buffer, NULL, NULL, &error);
-
- if (error != NULL) {
+ if (!g_file_load_contents (cue_sheet_file, NULL, &buffer, NULL, NULL, &error)) {
g_debug ("Unable to read cue sheet: %s", error->message);
g_error_free (error);
continue;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]