[vlc-devel] [PATCH] ML: Discard items with no URI in Append Queue.

Konstantin Pavlov thresh at videolan.org
Fri Mar 25 10:17:10 CET 2011


This fixes the crash when Media Library tries to add "My Videos" / "My
Pictures" / etc. playlist entries to a ML when browsing them through "My
Computer" service discovery.
---
 modules/media_library/ml_watch.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/modules/media_library/ml_watch.c b/modules/media_library/ml_watch.c
index f542d81..ca47dc0 100644
--- a/modules/media_library/ml_watch.c
+++ b/modules/media_library/ml_watch.c
@@ -538,6 +538,10 @@ static void watch_ProcessAppendQueue( media_library_t* p_ml )
     {
         input_item_t* p_item = p_wt->item_append_queue[i];
         ml_media_t* p_media = NULL;
+        /* Discard items with no uri */
+        if( !p_item->psz_uri )
+            continue;
+
         /* Is this item in ML? */
         int i_media_id = GetMediaIdOfURI( p_ml, p_item->psz_uri );
         int i_ret = 0;
-- 
1.7.4.1




More information about the vlc-devel mailing list