]> git.sesse.net Git - vlc/blobdiff - modules/services_discovery/daap.c
* added encap-formats information to the codec-info to the WX-Wizard as well (uncompi...
[vlc] / modules / services_discovery / daap.c
index 02b00e31a2b72e596b8f2d78726b5d7462077b63..cda6460e07072935d2557603dcf7318a5a2e14ab 100644 (file)
@@ -1,7 +1,7 @@
 /*****************************************************************************
  * daap.c :  Apple DAAP discovery module
  *****************************************************************************
- * Copyright (C) 2004 VideoLAN
+ * Copyright (C) 2004 the VideoLAN team
  * $Id: sap.c 9569 2004-12-15 22:17:52Z zorglub $
  *
  * Authors: ClĂ©ment Stenac <zorglub@videolan.org>
@@ -321,7 +321,7 @@ static void Close( vlc_object_t *p_this )
 
     if( p_playlist )
     {
-        playlist_NodeDelete( p_playlist, p_sys->p_node, VLC_TRUE );
+        playlist_NodeDelete( p_playlist, p_sys->p_node, VLC_TRUE, VLC_TRUE );
         vlc_object_release( p_playlist );
     }
 
@@ -508,6 +508,7 @@ static int EnumerateCallback( DAAP_SClient *p_client,
     if( !b_found )
     {
         dhost_t *p_vlchost = (dhost_t *)malloc( sizeof( dhost_t ) );
+        p_vlchost->p_node = NULL;
         p_vlchost->p_host = p_host;
         p_vlchost->psz_name = psz_buffer;
         p_vlchost->b_new = VLC_TRUE;
@@ -632,7 +633,9 @@ static void FreeHost( services_discovery_t *p_sd, dhost_t *p_host )
                                                  FIND_ANYWHERE );
     if( p_playlist )
     {
-        playlist_NodeDelete( p_playlist, p_host->p_node, VLC_TRUE );
+        if( p_host->p_node )
+            playlist_NodeDelete( p_playlist, p_host->p_node, VLC_TRUE ,
+                                                             VLC_TRUE);
         vlc_object_release( p_playlist );
     }