[vlc-commits] Fix Stack off-by-one overflow in vc1 packetizer
Jean-Baptiste Kempf
git at videolan.org
Tue May 15 14:45:25 CEST 2012
vlc/vlc-2.0 | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Sat May 12 02:10:58 2012 +0200| [f2a1e6ffe3080cdc69a99332040de89bc691bd4f] | committer: Jean-Baptiste Kempf
Fix Stack off-by-one overflow in vc1 packetizer
Pointed-By: Clément Lecigne
(cherry picked from commit 08879e4e4284cd5359578731701195e5d19c2f20)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.0.git/?a=commit;h=f2a1e6ffe3080cdc69a99332040de89bc691bd4f
---
modules/packetizer/vc1.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/modules/packetizer/vc1.c b/modules/packetizer/vc1.c
index e3c7daa..0859f68 100644
--- a/modules/packetizer/vc1.c
+++ b/modules/packetizer/vc1.c
@@ -285,7 +285,7 @@ static void DecodeRIDU( uint8_t *p_ret, int *pi_ret, uint8_t *src, int i_src )
while( src < end && dst < dst_end )
{
if( src < end - 3 && src[0] == 0x00 && src[1] == 0x00 &&
- src[2] == 0x03 )
+ src[2] == 0x03 && dst < dst_end - 1 )
{
*dst++ = 0x00;
*dst++ = 0x00;
More information about the vlc-commits
mailing list