[libav-devel] [PATCH 03/14] cbs: Use correct conversion specifier for unit type

Mark Thompson sw at jkqxz.net
Thu Nov 9 02:07:45 CET 2017


---
 libavcodec/cbs_h2645.c | 2 +-
 libavcodec/cbs_mpeg2.c | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/libavcodec/cbs_h2645.c b/libavcodec/cbs_h2645.c
index a1b887fd4..c4739a946 100644
--- a/libavcodec/cbs_h2645.c
+++ b/libavcodec/cbs_h2645.c
@@ -1206,7 +1206,7 @@ static int cbs_h265_write_nal_unit(CodedBitstreamContext *ctx,
 
     default:
         av_log(ctx->log_ctx, AV_LOG_ERROR, "Write unimplemented for "
-               "NAL unit type %d.\n", unit->type);
+               "NAL unit type %"PRIu32".\n", unit->type);
         return AVERROR_PATCHWELCOME;
     }
 
diff --git a/libavcodec/cbs_mpeg2.c b/libavcodec/cbs_mpeg2.c
index 3c09377df..3a41e5452 100644
--- a/libavcodec/cbs_mpeg2.c
+++ b/libavcodec/cbs_mpeg2.c
@@ -217,7 +217,7 @@ static int cbs_mpeg2_read_unit(CodedBitstreamContext *ctx,
             START(0xb8, MPEG2RawGroupOfPicturesHeader, group_of_pictures_header);
 #undef START
         default:
-            av_log(ctx->log_ctx, AV_LOG_ERROR, "Unknown start code %02x.\n",
+            av_log(ctx->log_ctx, AV_LOG_ERROR, "Unknown start code %02"PRIx32".\n",
                    unit->type);
             return AVERROR_INVALIDDATA;
         }
@@ -245,7 +245,7 @@ static int cbs_mpeg2_write_header(CodedBitstreamContext *ctx,
 #undef START
     default:
         av_log(ctx->log_ctx, AV_LOG_ERROR, "Write unimplemented for start "
-               "code %02x.\n", unit->type);
+               "code %02"PRIx32".\n", unit->type);
         return AVERROR_PATCHWELCOME;
     }
 
-- 
2.11.0



More information about the libav-devel mailing list