[rygel/rygel-0-28] media-export: Prevent criticals if playlist creation failed



commit c18c595556a76e9965d9266643078e7da7cf07d9
Author: Jens Georg <mail jensge org>
Date:   Sat Feb 20 23:56:53 2016 +0100

    media-export: Prevent criticals if playlist creation failed
    
    Signed-off-by: Jens Georg <mail jensge org>

 .../rygel-media-export-item-factory.vala           |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/plugins/media-export/rygel-media-export-item-factory.vala 
b/src/plugins/media-export/rygel-media-export-item-factory.vala
index 701759d..185b4d7 100644
--- a/src/plugins/media-export/rygel-media-export-item-factory.vala
+++ b/src/plugins/media-export/rygel-media-export-item-factory.vala
@@ -163,6 +163,9 @@ namespace Rygel.MediaExport.ItemFactory {
                 break;
             case Rygel.PlaylistItem.UPNP_CLASS:
                 item = ItemFactory.create_playlist_item (file, parent, "");
+                if (item == null) {
+                    return null;
+                }
                 break;
             default:
                 return null;


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