]> git.sesse.net Git - vlc/commitdiff
Format string fixes
authorRémi Denis-Courmont <rdenis@simphalempin.com>
Thu, 3 Jul 2008 17:39:21 +0000 (20:39 +0300)
committerRémi Denis-Courmont <rdenis@simphalempin.com>
Thu, 3 Jul 2008 17:47:02 +0000 (20:47 +0300)
modules/access/v4l2/v4l2.c
modules/access_filter/bandwidth.c
modules/codec/adpcm.c
modules/codec/avcodec/audio.c
modules/codec/cinepak.c
modules/codec/cvdsub.c
modules/codec/rawvideo.c
modules/codec/spudec/spudec.c
modules/codec/svcdsub.c
modules/demux/real.c

index 1bc4f35a59b9b1442ee402ca1a0c281f63d052d0..aa67b3633e01befa04d5e3a199cdb6c1f8b7fd2d 100644 (file)
@@ -1629,7 +1629,7 @@ static block_t* GrabAudio( demux_t *p_demux )
             /* Test for overrun */
             if( i_correction_delta > p_sys->i_audio_max_frame_size )
             {
-                msg_Warn( p_demux, "ALSA read overrun (%d > %d)",
+                msg_Warn( p_demux, "ALSA read overrun (%zu > %zu)",
                           i_correction_delta, p_sys->i_audio_max_frame_size );
                 i_correction_delta = p_sys->i_audio_max_frame_size;
                 snd_pcm_prepare( p_sys->p_alsa_pcm );
index ff00f9c709ee3b068bd66009e34cd61e4351c7e3..bc1d711e082845682f315626b898b509037f330c 100644 (file)
@@ -144,7 +144,7 @@ retry:
 
     if (len > delta)
     {
-        msg_Dbg (access, "reading %u bytes instead of %u", (unsigned)delta,
+        msg_Dbg (access, "reading %"PRIu64" bytes instead of %zu", delta,
                  len);
         len = (int)delta;
     }
index 9c280165ad7908467f17f2c211b4541431688d80..41ce99ee1268a4c3bf935f54569d5ad82e078a7f 100644 (file)
@@ -202,7 +202,7 @@ static int OpenDecoder( vlc_object_t *p_this )
     {
         p_sys->i_block = (p_sys->codec == ADPCM_IMA_QT) ?
             34 * p_dec->fmt_in.audio.i_channels : 1024;
-        msg_Warn( p_dec, "block size undefined, using %d", p_sys->i_block );
+        msg_Warn( p_dec, "block size undefined, using %zu", p_sys->i_block );
     }
     else
     {
index 2a65ad3733ce89390b3d9b7f2f2adfa392d60f0c..00793046f8ef87be58649b5900c7a2a086386a35 100644 (file)
@@ -293,7 +293,7 @@ aout_buffer_t * DecodeAudio ( decoder_t *p_dec, block_t **pp_block )
     if( i_used < 0 || i_output < 0 )
     {
         if( i_used < 0 )
-            msg_Warn( p_dec, "cannot decode one frame (%d bytes)",
+            msg_Warn( p_dec, "cannot decode one frame (%zu bytes)",
                       p_block->i_buffer );
 
         block_Release( p_block );
index fadcc2a7dfb176380ecfb8118e5346f785af9795..3a41336cbc7e8b9a214de4074f5780f39b5b2d4d 100644 (file)
@@ -154,7 +154,7 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
                                      p_block->p_buffer );
     if( i_status < 0 )
     {
-        msg_Warn( p_dec, "cannot decode one frame (%d bytes)",
+        msg_Warn( p_dec, "cannot decode one frame (%zu bytes)",
                   p_block->i_buffer );
         block_Release( p_block );
         return NULL;
index 119a327a18b665efe7c5bfc6069c4126c24e7d5b..48da421c6c9cd6d0c14b8a660380407d5b747653 100644 (file)
@@ -220,7 +220,7 @@ static block_t *Reassemble( decoder_t *p_dec, block_t *p_block )
 
     if( p_block->i_buffer < SPU_HEADER_LEN )
     {
-        msg_Dbg( p_dec, "invalid packet header (size %d < %d)" ,
+        msg_Dbg( p_dec, "invalid packet header (size %zu < %u)" ,
                  p_block->i_buffer, SPU_HEADER_LEN );
         block_Release( p_block );
         return NULL;
@@ -253,11 +253,11 @@ static block_t *Reassemble( decoder_t *p_dec, block_t *p_block )
 
         if( p_spu->i_buffer != p_sys->i_spu_size )
         {
-            msg_Warn( p_dec, "SPU packets size=%d should be %d",
+            msg_Warn( p_dec, "SPU packets size=%zu should be %zu",
                       p_spu->i_buffer, p_sys->i_spu_size );
         }
 
-        msg_Dbg( p_dec, "subtitle packet complete, size=%d", p_spu->i_buffer);
+        msg_Dbg( p_dec, "subtitle packet complete, size=%zuu", p_spu->i_buffer);
 
         ParseMetaInfo( p_dec, p_spu );
 
@@ -315,7 +315,7 @@ static void ParseHeader( decoder_t *p_dec, block_t *p_block )
     p_sys->i_image_length = p_sys->metadata_offset - p_sys->i_image_offset;
 
 #ifdef DEBUG_CVDSUB
-    msg_Dbg( p_dec, "total size: %d  image size: %d",
+    msg_Dbg( p_dec, "total size: %zu  image size: %zu",
              p_sys->i_spu_size, p_sys->i_image_length );
 #endif
 }
@@ -461,7 +461,8 @@ static void ParseMetaInfo( decoder_t *p_dec, block_t *p_spu  )
             p_sys->first_field_offset =
                 (p[2] << 8) + p[3] - p_sys->i_image_offset;
 #ifdef DEBUG_CVDSUB
-            msg_Dbg( p_dec, "1st_field_offset %d", p_sys->first_field_offset );
+            msg_Dbg( p_dec, "1st_field_offset %zu",
+                     p_sys->first_field_offset );
 #endif
             break;
 
@@ -471,7 +472,8 @@ static void ParseMetaInfo( decoder_t *p_dec, block_t *p_spu  )
             p_sys->second_field_offset =
                 (p[2] << 8) + p[3] - p_sys->i_image_offset;
 #ifdef DEBUG_CVDSUB
-            msg_Dbg( p_dec, "2nd_field_offset %d", p_sys->second_field_offset);
+            msg_Dbg( p_dec, "2nd_field_offset %zu",
+                     p_sys->second_field_offset);
 #endif
             break;
 
index ccca3fa6c574e7a622d4a6a13134b0aebc5549b1..c1498644df2659eb9b0803bedc629ee968974eac 100644 (file)
@@ -229,7 +229,7 @@ static void *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
 
     if( p_block->i_buffer < p_sys->i_raw_size )
     {
-        msg_Warn( p_dec, "invalid frame size (%d < %d)",
+        msg_Warn( p_dec, "invalid frame size (%zu < %zu)",
                   p_block->i_buffer, p_sys->i_raw_size );
 
         block_Release( p_block );
index 738539196958770da39620022b371a7a9151bf2a..5f4e83e3e7455ad650b0a109cf5ff884ab120983 100644 (file)
@@ -206,7 +206,7 @@ static block_t *Reassemble( decoder_t *p_dec, block_t **pp_block )
         ( p_block->i_pts <= 0 || p_block->i_buffer < 4 ) )
     {
         msg_Dbg( p_dec, "invalid starting packet (size < 4 or pts <=0)" );
-        msg_Dbg( p_dec, "spu size: %d, i_pts: %"PRId64" i_buffer: %d",
+        msg_Dbg( p_dec, "spu size: %d, i_pts: %"PRId64" i_buffer: %zu",
                  p_sys->i_spu_size, p_block->i_pts, p_block->i_buffer );
         block_Release( p_block );
         return NULL;
index 6e39aa4817851e7acf0fb02ecaf7672aeb07febf..b7bf4a9f9a1f26633b97f12c0733dd4ccc21ff93 100644 (file)
@@ -261,7 +261,7 @@ static block_t *Reassemble( decoder_t *p_dec, block_t *p_block )
 
     if( p_block->i_buffer < SPU_HEADER_LEN )
     {
-        msg_Dbg( p_dec, "invalid packet header (size %d < %d)" ,
+        msg_Dbg( p_dec, "invalid packet header (size %zu < %u)" ,
                  p_block->i_buffer, SPU_HEADER_LEN );
         block_Release( p_block );
         return NULL;
@@ -350,12 +350,12 @@ static block_t *Reassemble( decoder_t *p_dec, block_t *p_block )
 
         if( p_spu->i_buffer != p_sys->i_spu_size )
         {
-            msg_Warn( p_dec, "subtitle packets size=%d should be %d",
+            msg_Warn( p_dec, "subtitle packets size=%zu should be %zu",
                       p_spu->i_buffer, p_sys->i_spu_size );
         }
 
     dbg_print( (DECODE_DBG_PACKET),
-                 "subtitle packet complete, size=%d", p_spu->i_buffer );
+                 "subtitle packet complete, size=%zu", p_spu->i_buffer );
 
         p_sys->i_state = SUBTITLE_BLOCK_EMPTY;
         p_sys->p_spu = 0;
@@ -437,10 +437,10 @@ static void ParseHeader( decoder_t *p_dec, block_t *p_block )
   if (p_sys && p_sys->i_debug & DECODE_DBG_PACKET)
   {
       msg_Dbg( p_dec, "x-start: %d, y-start: %d, width: %d, height %d, "
-           "spu size: %d, duration: %lu (d:%d p:%d)",
+           "spu size: %zu, duration: %"PRIu64" (d:%zu p:%"PRIu16")",
            p_sys->i_x_start, p_sys->i_y_start,
            p_sys->i_width, p_sys->i_height,
-           p_sys->i_spu_size, (long unsigned int) p_sys->i_duration,
+           p_sys->i_spu_size, p_sys->i_duration,
            p_sys->i_image_length, p_sys->i_image_offset);
  
       for( i = 0; i < 4; i++ )
index 4ed3e0386a04626b7ea13f2aa6b7e961514c3327..5d5d40d0f3d0e4e38c215b04851e87ebee76fc6b 100644 (file)
@@ -401,7 +401,7 @@ static int Demux( demux_t *p_demux )
                 ( tk->p_frame->i_dts != i_pts ||
                   tk->i_frame != i_len ) )
             {
-                msg_Dbg( p_demux, "sending size=%d", tk->p_frame->i_buffer );
+                msg_Dbg( p_demux, "sending size=%zu", tk->p_frame->i_buffer );
 
                 es_out_Send( p_demux->out, tk->p_es, tk->p_frame );