]> git.sesse.net Git - vlc/commitdiff
Stream out: fix memleak.
authorRémi Duraffort <ivoire@videolan.org>
Thu, 31 Jul 2008 12:57:28 +0000 (14:57 +0200)
committerRémi Duraffort <ivoire@videolan.org>
Thu, 31 Jul 2008 12:57:28 +0000 (14:57 +0200)
modules/stream_out/standard.c

index 09fa0448e72ddb0dc804075d13754adb3204227d..72b97e73f11baefbef960555fc75031abeaa9820 100644 (file)
@@ -278,6 +278,7 @@ static int Open( vlc_object_t *p_this )
         else
         {
             msg_Err( p_stream, "no access _and_ no muxer (fatal error)" );
+            free( p_sys );
             return VLC_EGENERIC;
         }
     }
@@ -300,6 +301,7 @@ static int Open( vlc_object_t *p_this )
         else
         {
             msg_Err( p_stream, "no mux specified or found by extension" );
+            free( p_sys );
             return VLC_EGENERIC;
         }
     }
@@ -368,6 +370,7 @@ static int Open( vlc_object_t *p_this )
                  psz_access, psz_mux, psz_url );
         free( psz_access );
         free( psz_mux );
+        free( p_sys );
         return VLC_EGENERIC;
     }
     msg_Dbg( p_stream, "access opened" );
@@ -382,6 +385,7 @@ static int Open( vlc_object_t *p_this )
         sout_AccessOutDelete( p_access );
         free( psz_access );
         free( psz_mux );
+        free( p_sys );
         return VLC_EGENERIC;
     }
     msg_Dbg( p_stream, "mux opened" );