OSDN Git Service
(root)
/
coroid
/
ffmpeg_saccubus.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c940c31
)
Make buffer size check consistent and avoid a possible overflow.
author
Reimar Döffinger
<Reimar.Doeffinger@gmx.de>
Wed, 15 Jun 2011 18:21:33 +0000
(20:21 +0200)
committer
Reimar Döffinger
<Reimar.Doeffinger@gmx.de>
Wed, 15 Jun 2011 18:21:33 +0000
(20:21 +0200)
libavformat/rtpenc_h264.c
patch
|
blob
|
history
diff --git
a/libavformat/rtpenc_h264.c
b/libavformat/rtpenc_h264.c
index
0f8850e
..
11074d0
100644
(file)
--- a/
libavformat/rtpenc_h264.c
+++ b/
libavformat/rtpenc_h264.c
@@
-40,7
+40,7
@@
static const uint8_t *avc_mp4_find_startcode(const uint8_t *start, const uint8_t
res = (res << 8) | *start++;
}
- if (
res + start > end
) {
+ if (
end - start < res
) {
return NULL;
}