diff options
author | Devin Heitmueller <devin.heitmueller@ltnglobal.com> | 2023-03-17 11:02:31 -0400 |
---|---|---|
committer | Marton Balint <cus@passwd.hu> | 2023-04-02 21:31:05 +0200 |
commit | 85c62b48e9189d84746009f26a4cff41ad5d4603 (patch) | |
tree | dd4a4c1f2913e870627d2d7dc3e20a36a393aa8c /libavcodec | |
parent | 9d140ecaf80762aa13a71ea528ec4431e0355ed1 (diff) | |
download | ffmpeg-85c62b48e9189d84746009f26a4cff41ad5d4603.tar.gz |
avcodec/bytestream: fix warnings with signed/unsigned compare in bytestream.h
When including the header in decklink_enc.cpp it would be fed
through the C++ compiler rather than the C compiler, which has
more strict warnings when comparing signed/unsigned values.
Make the local variables unsigned to match the arguments they are
being passed for those functions.
Signed-off-by: Devin Heitmueller <dheitmueller@ltnglobal.com>
Signed-off-by: Marton Balint <cus@passwd.hu>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/bytestream.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libavcodec/bytestream.h b/libavcodec/bytestream.h index d0033f14f3..67080604b9 100644 --- a/libavcodec/bytestream.h +++ b/libavcodec/bytestream.h @@ -180,7 +180,7 @@ static av_always_inline void bytestream2_skipu(GetByteContext *g, static av_always_inline void bytestream2_skip_p(PutByteContext *p, unsigned int size) { - int size2; + unsigned int size2; if (p->eof) return; size2 = FFMIN(p->buffer_end - p->buffer, size); @@ -268,7 +268,7 @@ static av_always_inline unsigned int bytestream2_get_buffer(GetByteContext *g, uint8_t *dst, unsigned int size) { - int size2 = FFMIN(g->buffer_end - g->buffer, size); + unsigned int size2 = FFMIN(g->buffer_end - g->buffer, size); memcpy(dst, g->buffer, size2); g->buffer += size2; return size2; @@ -287,7 +287,7 @@ static av_always_inline unsigned int bytestream2_put_buffer(PutByteContext *p, const uint8_t *src, unsigned int size) { - int size2; + unsigned int size2; if (p->eof) return 0; size2 = FFMIN(p->buffer_end - p->buffer, size); @@ -311,7 +311,7 @@ static av_always_inline void bytestream2_set_buffer(PutByteContext *p, const uint8_t c, unsigned int size) { - int size2; + unsigned int size2; if (p->eof) return; size2 = FFMIN(p->buffer_end - p->buffer, size); @@ -348,7 +348,7 @@ static av_always_inline unsigned int bytestream2_copy_buffer(PutByteContext *p, GetByteContext *g, unsigned int size) { - int size2; + unsigned int size2; if (p->eof) return 0; |