[vlc-commits] AVI: better debug

Jean-Baptiste Kempf git at videolan.org
Thu May 24 14:30:51 CEST 2012


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Thu May 24 12:57:30 2012 +0200| [ea52acf756607b5e12a7558e3182ecf9d7d59e72] | committer: Jean-Baptiste Kempf

AVI: better debug

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=ea52acf756607b5e12a7558e3182ecf9d7d59e72
---

 modules/demux/avi/libavi.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/modules/demux/avi/libavi.c b/modules/demux/avi/libavi.c
index 176c47d..016ec71 100644
--- a/modules/demux/avi/libavi.c
+++ b/modules/demux/avi/libavi.c
@@ -67,8 +67,7 @@ static int AVI_ChunkReadCommon( stream_t *s, avi_chunk_t *p_chk )
 
 #ifdef AVI_DEBUG
     msg_Dbg( (vlc_object_t*)s,
-             "found Chunk fourcc:%8.8x (%4.4s) size:%"PRId64" pos:%"PRId64,
-             p_chk->common.i_chunk_fourcc,
+             "found chunk, fourcc: %4.4s size:%"PRId64" pos:%"PRId64,
              (char*)&p_chk->common.i_chunk_fourcc,
              p_chk->common.i_chunk_size,
              p_chk->common.i_chunk_pos );
@@ -790,6 +789,7 @@ int  AVI_ChunkRead( stream_t *s, avi_chunk_t *p_chk, avi_chunk_t *p_father )
 
     if( !p_chk )
     {
+        msg_Warn( (vlc_object_t*)s, "cannot read null chunk" );
         return VLC_EGENERIC;
     }
 
@@ -798,6 +798,7 @@ int  AVI_ChunkRead( stream_t *s, avi_chunk_t *p_chk, avi_chunk_t *p_father )
         msg_Warn( (vlc_object_t*)s, "cannot read one chunk" );
         return VLC_EGENERIC;
     }
+
     if( p_chk->common.i_chunk_fourcc == VLC_FOURCC( 0, 0, 0, 0 ) )
     {
         msg_Warn( (vlc_object_t*)s, "found null fourcc chunk (corrupted file?)" );
@@ -818,6 +819,7 @@ int  AVI_ChunkRead( stream_t *s, avi_chunk_t *p_chk, avi_chunk_t *p_father )
         p_chk->common.i_chunk_fourcc = AVIFOURCC_indx;
         return AVI_ChunkRead_indx( s, p_chk );
     }
+
     msg_Warn( (vlc_object_t*)s, "unknown chunk: %4.4s (not loaded)",
             (char*)&p_chk->common.i_chunk_fourcc );
     return AVI_NextChunk( s, p_chk );



More information about the vlc-commits mailing list