]> git.sesse.net Git - vlc/commitdiff
remove memory leak
authorRémi Duraffort <ivoire@videolan.org>
Sun, 23 Dec 2007 08:12:26 +0000 (08:12 +0000)
committerRémi Duraffort <ivoire@videolan.org>
Sun, 23 Dec 2007 08:12:26 +0000 (08:12 +0000)
src/misc/update.c

index c0b99737ca9ca7db0967c913a9d2f8a7770c5b21..32f474afc5d316a2b1c3d97e878ed77dda4f0e95 100644 (file)
@@ -922,6 +922,8 @@ void update_CheckReal( update_check_thread_t *p_uct )
 
     if( p_uct->pf_callback )
         (p_uct->pf_callback)( p_uct->p_data );
+
+    vlc_object_destroy( p_uct );
 }
 
 /**
@@ -1021,6 +1023,7 @@ void update_Download( update_t *p_update, char *psz_destdir )
     vlc_thread_create( p_udt, "download update", update_DownloadReal,
                        VLC_THREAD_PRIORITY_LOW, VLC_FALSE );
 }
+
 void update_DownloadReal( update_download_thread_t *p_udt )
 {
     int i_progress = 0;
@@ -1123,6 +1126,8 @@ error:
     free( psz_destfile );
     free( p_buffer );
     free( psz_size );
+
+    vlc_object_destroy( p_udt );
 }
 
 #endif