mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-01-18 13:21:08 +00:00
Change CHECK_STREAM_PTR macro to correctly handle the (extremely unlikely)
overflow case. Originally committed as revision 18224 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
3017d8e9d7
commit
a1f6ffd44d
@ -76,7 +76,7 @@ typedef struct IpvideoContext {
|
||||
} IpvideoContext;
|
||||
|
||||
#define CHECK_STREAM_PTR(n) \
|
||||
if ((s->stream_ptr + n) > s->stream_end) { \
|
||||
if (s->stream_end - s->stream_ptr < n) { \
|
||||
av_log(s->avctx, AV_LOG_ERROR, "Interplay video warning: stream_ptr out of bounds (%p >= %p)\n", \
|
||||
s->stream_ptr + n, s->stream_end); \
|
||||
return -1; \
|
||||
|
Loading…
Reference in New Issue
Block a user