]> git.sesse.net Git - vlc/commitdiff
* src/video_output/video_output.c: we were still using free instead of
authorGildas Bazin <gbazin@videolan.org>
Thu, 30 Jan 2003 19:14:17 +0000 (19:14 +0000)
committerGildas Bazin <gbazin@videolan.org>
Thu, 30 Jan 2003 19:14:17 +0000 (19:14 +0000)
   vout_DestroySubPicture in one place.
* modules/codec/spudec/parse.c: we now make sure we don't add several times
   the same highlight callback.

modules/codec/spudec/parse.c
src/video_output/video_output.c

index 81089876fd9922de66822657963c1ddb8e26f636..669e64dba3d82917fb6c69edf4dd0e75c49e2384 100644 (file)
@@ -2,7 +2,7 @@
  * parse.c: SPU parser
  *****************************************************************************
  * Copyright (C) 2000-2001 VideoLAN
- * $Id: parse.c,v 1.9 2003/01/17 13:54:11 sam Exp $
+ * $Id: parse.c,v 1.10 2003/01/30 19:14:17 gbazin Exp $
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *
@@ -166,6 +166,8 @@ void E_(ParsePacket)( spudec_thread_t *p_spudec )
 
             vlc_mutex_lock( p_mutex );
             UpdateSPU( p_spu, VLC_OBJECT(p_spu->p_sys->p_input) );
+            var_DelCallback( p_spu->p_sys->p_input,
+                             "highlight", CropCallback, p_spu );
             var_AddCallback( p_spu->p_sys->p_input,
                              "highlight", CropCallback, p_spu );
             vlc_mutex_unlock( p_mutex );
index 88c3d8cc4ce24f60b13a49a3d8fad7907335d0d4..1048e3f13704e607c650a0cffdf4211a9cf8cba0 100644 (file)
@@ -5,7 +5,7 @@
  * thread, and destroy a previously oppened video output thread.
  *****************************************************************************
  * Copyright (C) 2000-2001 VideoLAN
- * $Id: video_output.c,v 1.210 2003/01/28 22:03:21 sam Exp $
+ * $Id: video_output.c,v 1.211 2003/01/30 19:14:17 gbazin Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *
@@ -930,7 +930,8 @@ static void EndThread( vout_thread_t *p_vout )
     {
         if( p_vout->p_subpicture[i_index].i_status != FREE_SUBPICTURE )
         {
-            free( p_vout->p_subpicture[i_index].p_sys );
+            vout_DestroySubPicture( p_vout,
+                                    &p_vout->p_subpicture[i_index] );
         }
     }