rss: fix object leak.
[vlc.git] / modules / video_filter / rss.c
index 244c871..5f407d6 100644 (file)
@@ -46,7 +46,7 @@
 #include <vlc_xml.h>
 #include <vlc_charset.h>
 
-#include "vlc_image.h"
+#include <vlc_image.h>
 
 #include <time.h>
 
@@ -717,6 +717,7 @@ static int FetchRSS( filter_t *p_filter)
         if( !p_stream )
         {
             msg_Err( p_filter, "Failed to open %s for reading", psz_feed );
+            xml_Delete( p_xml );
             return 1;
         }
 
@@ -724,6 +725,7 @@ static int FetchRSS( filter_t *p_filter)
         if( !p_xml_reader )
         {
             msg_Err( p_filter, "Failed to open %s for parsing", psz_feed );
+            xml_Delete( p_xml );
             return 1;
         }