[rhythmbox] rhythmdb: check entry was added before attempting to cache metadata
- From: Jonathan Matthew <jmatthew src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [rhythmbox] rhythmdb: check entry was added before attempting to cache metadata
- Date: Mon, 7 Mar 2016 12:14:08 +0000 (UTC)
commit 036ed0a652b203004ed4b037de3bda8005e0b374
Author: Jonathan Matthew <jonathan d14n org>
Date: Mon Mar 7 22:11:15 2016 +1000
rhythmdb: check entry was added before attempting to cache metadata
rhythmdb_add_import_error_entry doesn't always create an entry.
https://bugzilla.gnome.org/show_bug.cgi?id=763206
rhythmdb/rhythmdb.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/rhythmdb/rhythmdb.c b/rhythmdb/rhythmdb.c
index cffead3..1013f78 100644
--- a/rhythmdb/rhythmdb.c
+++ b/rhythmdb/rhythmdb.c
@@ -2528,7 +2528,9 @@ rhythmdb_process_metadata_load (RhythmDB *db, RhythmDBEvent *event)
_("Empty file"));
} else if (file_size < REALLY_SMALL_FILE_SIZE) {
entry = rhythmdb_add_import_error_entry (db, event, event->ignore_type);
- rhythmdb_entry_cache_metadata (entry);
+ if (entry != NULL) {
+ rhythmdb_entry_cache_metadata (entry);
+ }
return TRUE;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]