[prev in list] [next in list] [prev in thread] [next in thread] 

List:       helix-datatype-cvs
Subject:    [Datatype-cvs] mp3/fileformat mp3ff.cpp,1.58.2.12,1.58.2.12.2.1
From:       sgarg () helixcommunity ! org
Date:       2010-09-28 10:10:17
Message-ID: 201009281010.o8SAAJDA014225 () mailer ! progressive-comp ! com
[Download RAW message or body]

Update of /cvsroot/datatype/mp3/fileformat
In directory cvs01.internal.helixcommunity.org:/tmp/cvs-serv16523

Modified Files:
      Tag: hxclient_3_4_11_atlas
	mp3ff.cpp 
Log Message:
Merge changes from 361Atlas to 3411Atlas to fix Bug 11465 - [LGN] Corrupted MP3 file \
caused Helix to consume almost CPU power.

Index: mp3ff.cpp
===================================================================
RCS file: /cvsroot/datatype/mp3/fileformat/mp3ff.cpp,v
retrieving revision 1.58.2.12
retrieving revision 1.58.2.12.2.1
diff -u -d -r1.58.2.12 -r1.58.2.12.2.1
--- mp3ff.cpp	23 Dec 2009 03:19:16 -0000	1.58.2.12
+++ mp3ff.cpp	28 Sep 2010 10:10:14 -0000	1.58.2.12.2.1
@@ -1659,9 +1659,21 @@
 
            if(lHeaderSize > pBufLen)
            {
-               m_ulNewReadSize = lHeaderSize; 
-               m_State = GetFileHeaderSeekPendingAttempt2;
-               m_pFileObj->Seek(MY_FILE_HEADER_START, FALSE);
+               if (m_ulNewReadSize > 0 && m_ulNewReadSize > pBufLen)
+               {
+                   // Since have already try one more time, but still can not get
+                   // file header, report file corrupt error here
+                   m_pError->Report(HXLOG_ERR, HXR_CORRUPT_FILE, 0,
+                         "MP3 file corrupted",
+                         MY_MORE_INFO_URL);
+                   return HXR_CORRUPT_FILE;
+               }
+               else
+               {
+                   m_ulNewReadSize = lHeaderSize; 
+                   m_State = GetFileHeaderSeekPendingAttempt2;
+                   m_pFileObj->Seek(MY_FILE_HEADER_START, FALSE);
+               }
            }
            else
            {


_______________________________________________
Datatype-cvs mailing list
Datatype-cvs@helixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/datatype-cvs


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic