[Ffmpeg-devel] [PATCH] use proper PRI?64 macros for %ll? format

Dominik 'Rathann' Mierzejewski dominik
Sat Oct 14 19:30:38 CEST 2006


Hi.

This fixes a few printf format warnings:
utils.c:833: warning: format ?%lld? expects type ?long long int?, but argument 5 has type ?int64_t?
utils.c:833: warning: format ?%lld? expects type ?long long int?, but argument 6 has type ?int64_t?
utils.c:854: warning: format ?%lld? expects type ?long long int?, but argument 5 has type ?int64_t?
utils.c:854: warning: format ?%lld? expects type ?long long int?, but argument 6 has type ?int64_t?

asf.c:872: warning: format ?%Lx? expects type ?long long unsigned int?, but argument 4 has type ?int64_t?

mov.c:1754: warning: format ?%llx? expects type ?long long unsigned int?, but argument 5 has type ?int64_t?

Regards,
R.

-- 
MPlayer developer and RPMs maintainer: http://rpm.greysector.net/mplayer/
There should be a science of discontent. People need hard times and
oppression to develop psychic muscles.
	-- from "Collected Sayings of Muad'Dib" by the Princess Irulan
-------------- next part --------------
--- MPlayer-20114/libavformat/asf.c.lavc-printf	2006-10-08 16:12:06.000000000 +0200
+++ MPlayer-20114/libavformat/asf.c	2006-10-08 20:15:26.000000000 +0200
@@ -869,7 +869,7 @@
         itime=get_le64(&s->pb);
         pct=get_le32(&s->pb);
         ict=get_le32(&s->pb);
-        av_log(NULL, AV_LOG_DEBUG, "itime:0x%Lx, pct:%d, ict:%d\n",itime,pct,ict);
+        av_log(NULL, AV_LOG_DEBUG, "itime:0x%"PRIx64", pct:%d, ict:%d\n",itime,pct,ict);
 
         for (i=0;i<ict;i++){
             int pktnum=get_le32(&s->pb);
@@ -933,7 +933,7 @@
     //     }
 
         /* do the seek */
-        av_log(NULL, AV_LOG_DEBUG, "SEEKTO: %Ld\n", pos);
+        av_log(NULL, AV_LOG_DEBUG, "SEEKTO: %"PRId64"\n", pos);
         url_fseek(&s->pb, pos, SEEK_SET);
     }
     asf_reset_header(s);
--- MPlayer-20114/libavformat/mov.c.lavc-printf	2006-10-08 16:12:06.000000000 +0200
+++ MPlayer-20114/libavformat/mov.c	2006-10-08 21:53:01.000000000 +0200
@@ -1749,7 +1749,7 @@
     /* must be done just before reading, to avoid infinite loop on sample */
     sc->current_sample++;
     if (sample->pos >= url_fsize(&s->pb)) {
-        av_log(mov->fc, AV_LOG_ERROR, "stream %d, offset 0x%llx: partial file\n", sc->ffindex, sample->pos);
+        av_log(mov->fc, AV_LOG_ERROR, "stream %d, offset 0x%"PRIx64": partial file\n", sc->ffindex, sample->pos);
         return -1;
     }
 #ifdef CONFIG_DV_DEMUXER
--- MPlayer-20114/libavformat/utils.c.lavc-printf	2006-10-08 16:12:06.000000000 +0200
+++ MPlayer-20114/libavformat/utils.c	2006-10-08 20:15:26.000000000 +0200
@@ -826,7 +826,7 @@
 
             st = s->streams[s->cur_pkt.stream_index];
             if(st->codec->debug & FF_DEBUG_PTS)
-                av_log(s, AV_LOG_DEBUG, "av_read_packet stream=%d, pts=%lld, dts=%lld, size=%d\n",
+                av_log(s, AV_LOG_DEBUG, "av_read_packet stream=%d, pts=%"PRId64", dts=%"PRId64", size=%d\n",
                     s->cur_pkt.stream_index,
                     s->cur_pkt.pts,
                     s->cur_pkt.dts,
@@ -847,7 +847,7 @@
         }
     }
     if(st->codec->debug & FF_DEBUG_PTS)
-        av_log(s, AV_LOG_DEBUG, "av_read_frame_internal stream=%d, pts=%lld, dts=%lld, size=%d\n",
+        av_log(s, AV_LOG_DEBUG, "av_read_frame_internal stream=%d, pts=%"PRId64", dts=%"PRId64", size=%d\n",
             pkt->stream_index,
             pkt->pts,
             pkt->dts,



More information about the ffmpeg-devel mailing list