[rhythmbox] rhythmbox: Don't warn when a library entry is a podcast



commit f55ff2e2ef90836f7689f7e0843c1a32831873bf
Author: Bastien Nocera <hadess hadess net>
Date:   Thu Feb 24 17:58:50 2011 +0000

    rhythmbox: Don't warn when a library entry is a podcast
    
    https://bugzilla.gnome.org/show_bug.cgi?id=643165

 rhythmdb/rhythmdb.c |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/rhythmdb/rhythmdb.c b/rhythmdb/rhythmdb.c
index 301df28..22c247d 100644
--- a/rhythmdb/rhythmdb.c
+++ b/rhythmdb/rhythmdb.c
@@ -2129,8 +2129,15 @@ rhythmdb_process_stat_event (RhythmDB *db,
 			guint64 new_size;
 
 			/* update the existing entry, as long as the entry type matches */
-			if ((event->entry_type != NULL) && (entry->type != event->entry_type))
+			if ((event->entry_type != NULL) && (entry->type != event->entry_type)) {
+				if (event->entry_type == RHYTHMDB_ENTRY_TYPE_SONG &&
+				    entry->type == RHYTHMDB_ENTRY_TYPE_PODCAST_POST) {
+					rb_debug ("Ignoring stat event for '%s', it's already loaded as a podcast",
+						  rb_refstring_get (event->real_uri));
+					break;
+				}
 				g_warning ("attempt to use same location in multiple entry types");
+			}
 
 			if (entry->type == event->ignore_type)
 				rb_debug ("ignoring %p", entry);



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