Remove useless check and assignment
authorRémi Denis-Courmont <remi@remlab.net>
Wed, 14 Oct 2009 16:25:33 +0000 (19:25 +0300)
committerRémi Denis-Courmont <remi@remlab.net>
Wed, 14 Oct 2009 16:25:33 +0000 (19:25 +0300)
modules/services_discovery/sap.c

index 234d98f..94cf482 100644 (file)
@@ -468,11 +468,10 @@ static void Close( vlc_object_t *p_this )
 static void CloseDemux( vlc_object_t *p_this )
 {
     demux_t *p_demux = (demux_t *)p_this;
-    if( p_demux->p_sys )
-    {
-        if( p_demux->p_sys->p_sdp ) { FreeSDP( p_demux->p_sys->p_sdp ); p_demux->p_sys->p_sdp = NULL; }
-        free( p_demux->p_sys );
-    }
+
+    if( p_demux->p_sys->p_sdp )
+        FreeSDP( p_demux->p_sys->p_sdp );
+    free( p_demux->p_sys );
 }
 
 /*****************************************************************************