[FFmpeg-soc] [soc]: r5814 - mms/mmst.c

spyfeng subversion at mplayerhq.hu
Sun May 23 06:05:46 CEST 2010


Author: spyfeng
Date: Sun May 23 06:05:46 2010
New Revision: 5814

Log:
fix a possible array overwriting bug.

Modified:
   mms/mmst.c

Modified: mms/mmst.c
==============================================================================
--- mms/mmst.c	Sun May 23 05:50:36 2010	(r5813)
+++ mms/mmst.c	Sun May 23 06:05:46 2010	(r5814)
@@ -291,7 +291,7 @@ static MMSSCPacketType get_tcp_server_re
                 mms->incoming_flags       = mms->in_buffer[5];
 
                 if (length_remaining < 0
-                        || length_remaining > sizeof(mms->in_buffer)) {
+                        || length_remaining > sizeof(mms->in_buffer) - 8) {
                     dprintf("Incoming data len %d exceeds buffer len %d\n",
                             length_remaining, sizeof(mms->in_buffer));
                     return -1;


More information about the FFmpeg-soc mailing list