[rhythmbox] mtp: don't crash handling albums with no name
- From: Jonathan Matthew <jmatthew src gnome org>
- To: svn-commits-list gnome org
- Subject: [rhythmbox] mtp: don't crash handling albums with no name
- Date: Fri, 17 Jul 2009 11:47:52 +0000 (UTC)
commit 8194026419c2df4314ba046ca12b719276760092
Author: Jonathan Matthew <jonathan d14n org>
Date: Fri Jul 17 21:47:25 2009 +1000
mtp: don't crash handling albums with no name
plugins/mtpdevice/rb-mtp-source.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/plugins/mtpdevice/rb-mtp-source.c b/plugins/mtpdevice/rb-mtp-source.c
index 33e24f6..2508d38 100644
--- a/plugins/mtpdevice/rb-mtp-source.c
+++ b/plugins/mtpdevice/rb-mtp-source.c
@@ -673,6 +673,9 @@ load_mtp_db_idle_cb (RBMtpSource* source)
LIBMTP_album_t *album;
for (album = albums; album != NULL; album = album->next) {
+ if (album->name == NULL)
+ continue;
+
rb_debug ("album: %s, %d tracks", album->name, album->no_tracks);
g_hash_table_insert (priv->album_map, album->name, album);
if (album->no_tracks != 0) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]