]> git.sesse.net Git - ffmpeg/commitdiff
Corrections so that builds with DEBUG work
authorMichel Bardiaux <mbardiaux@mediaxim.be>
Thu, 8 Mar 2007 14:49:43 +0000 (14:49 +0000)
committerMichel Bardiaux <mbardiaux@mediaxim.be>
Thu, 8 Mar 2007 14:49:43 +0000 (14:49 +0000)
Originally committed as revision 8295 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavcodec/h263dec.c
libavcodec/wma.c
libavformat/rtp_h264.c
libavutil/internal.h

index 9246b52171390011f53d29de71e01d81f0821c99..b385f84cdad9b6c37a84d6c58e7531c0c2c3b290 100644 (file)
@@ -429,7 +429,8 @@ uint64_t time= rdtsc();
 #endif
 #ifdef DEBUG
     av_log(avctx, AV_LOG_DEBUG, "*****frame %d size=%d\n", avctx->frame_number, buf_size);
-    av_log(avctx, AV_LOG_DEBUG, "bytes=%x %x %x %x\n", buf[0], buf[1], buf[2], buf[3]);
+    if(buf_size>0)
+        av_log(avctx, AV_LOG_DEBUG, "bytes=%x %x %x %x\n", buf[0], buf[1], buf[2], buf[3]);
 #endif
     s->flags= avctx->flags;
     s->flags2= avctx->flags2;
index 75d5d2177e39b000fdf52bb586aa5865698be9ca..27a84ea8961c82c11afeb3f72bd63f7b95bacd17 100644 (file)
@@ -171,7 +171,7 @@ int ff_wma_init(AVCodecContext * avctx, int flags2)
             high_freq = high_freq * 0.5;
         }
     }
-    dprintf("flags1=0x%x flags2=0x%x\n", flags1, flags2);
+    dprintf("flags2=0x%x\n", flags2);
     dprintf("version=%d channels=%d sample_rate=%d bitrate=%d block_align=%d\n",
            s->version, s->nb_channels, s->sample_rate, s->bit_rate,
            s->block_align);
index 2d31822788830c0b13318b887e6481dbfff4ecfa..d38e8780d82e59db2a5a61921d7c940c9d1b0c8a 100644 (file)
@@ -164,7 +164,9 @@ static int h264_handle_packet(RTPDemuxContext * s,
                               const uint8_t * buf,
                               int len)
 {
-//    h264_rtp_extra_data *data = s->dynamic_protocol_context;
+#ifdef DEBUG
+    h264_rtp_extra_data *data = s->dynamic_protocol_context;
+#endif
     uint8_t nal = buf[0];
     uint8_t type = (nal & 0x1f);
     int result= 0;
index 1a54acae7f5446d28da771e7507a362b98ed5538..a391f9cb2b077e90fda63b8e6973b465365f5d95 100644 (file)
 
 /* dprintf macros */
 #ifdef DEBUG
-#    define dprintf(fmt,...) av_log(NULL, AV_LOG_DEBUG, fmt, __VA_ARGS__)
+#    define dprintf(...) av_log(NULL, AV_LOG_DEBUG, __VA_ARGS__)
 #else
-#    define dprintf(fmt,...)
+#    define dprintf(...)
 #endif
 
 #define av_abort()      do { av_log(NULL, AV_LOG_ERROR, "Abort at %s:%d\n", __FILE__, __LINE__); abort(); } while (0)