]> git.sesse.net Git - vlc/blobdiff - modules/codec/quicktime.c
Why are this variable unused ? (commented out for the moment as it memleak)
[vlc] / modules / codec / quicktime.c
index 8833a8b2239866d514c8dfe4c700e69920543519..1487920fb5b0c1a3dbfcced0aa753b9dba669c47 100644 (file)
@@ -5,7 +5,7 @@
  * $Id$
  *
  * Authors: Laurent Aimar <fenrir at via.ecp.fr>
- *          Derk-Jan Hartman <thedj at users.sf.net>
+ *          Derk-Jan Hartman <hartman at videolan.org>>
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -66,7 +66,7 @@ static void Close( vlc_object_t * );
 
 vlc_module_begin();
     set_description( N_("QuickTime library decoder") );
-    set_capability( "decoder", 100 );
+    set_capability( "decoder", 10 );
     set_category( CAT_INPUT );
     set_subcategory( SUBCAT_INPUT_VCODEC );
     set_callbacks( Open, Close );
@@ -242,7 +242,6 @@ static int Open( vlc_object_t *p_this )
     switch( p_dec->fmt_in.i_codec )
     {
         case VLC_FOURCC('h','2','6','4'): /* H.264 */
-        case VLC_FOURCC('a','v','c','1'): /* dto. */
         case VLC_FOURCC('c','v','i','d'): /* Cinepak */
         case VLC_FOURCC('I','V','4','1'): /* Indeo Video IV */
         case VLC_FOURCC('i','v','4','1'): /* dto. */
@@ -805,7 +804,8 @@ static int OpenVideo( decoder_t *p_dec )
     p_sys->framedescHandle = (ImageDescriptionHandle) NewHandleClear( id->idSize );
     memcpy( *p_sys->framedescHandle, id, id->idSize );
 
-    p_sys->plane = malloc( p_dec->fmt_in.video.i_width * p_dec->fmt_in.video.i_height * 3 );
+    if( p_dec->fmt_in.video.i_width != 0 && p_dec->fmt_in.video.i_height != 0) 
+        p_sys->plane = malloc( p_dec->fmt_in.video.i_width * p_dec->fmt_in.video.i_height * 3 );
     if( !p_sys->plane )
         goto exit_error;
 
@@ -905,11 +905,13 @@ static picture_t *DecodeVideo( decoder_t *p_dec, block_t **pp_block )
     {
         p_sys->i_late = 0;
     }
+#ifndef NDEBUG
     msg_Dbg( p_dec, "bufsize: %d", (int)p_block->i_buffer);
+#endif
 
     if( p_sys->i_late > 10 )
     {
-        msg_Dbg( p_dec, "too late buffer -> dropped" );
+        msg_Dbg( p_dec, "late buffer dropped (%"PRId64")", i_pts );
         block_Release( p_block );
         return NULL;
     }