workaround to support APE Tag v2

Original commit message from CVS:
workaround to support APE Tag v2
This commit is contained in:
Jeremy Simon 2003-04-25 20:21:50 +00:00
parent 42a4abb285
commit ed6cf23b38

View file

@ -240,10 +240,11 @@ int CAPETag::Analyze()
APE_TAG_FOOTER APETagFooter; APE_TAG_FOOTER APETagFooter;
m_spIO->Seek(-int(sizeof(APE_TAG_FOOTER)), FILE_END); m_spIO->Seek(-int(sizeof(APE_TAG_FOOTER)), FILE_END);
nRetVal = m_spIO->Read((unsigned char *) &APETagFooter, sizeof(APE_TAG_FOOTER), &nBytesRead); nRetVal = m_spIO->Read((unsigned char *) &APETagFooter, sizeof(APE_TAG_FOOTER), &nBytesRead);
if ((nBytesRead == sizeof(APE_TAG_FOOTER)) && (nRetVal == 0)) if ((nBytesRead == sizeof(APE_TAG_FOOTER)) && (nRetVal == 0))
{ {
if ((strncmp(APETagFooter.cID, "APETAGEX", 8) == 0) && if ((strncmp(APETagFooter.cID, "APETAGEX", 8) == 0) &&
(APETagFooter.nVersion <= CURRENT_APE_TAG_VERSION) && /*(APETagFooter.nVersion <= CURRENT_APE_TAG_VERSION) &&*/
(APETagFooter.nFields <= 65536) && (APETagFooter.nFields <= 65536) &&
(APETagFooter.nSize <= (1024 * 1024 * 16))) (APETagFooter.nSize <= (1024 * 1024 * 16)))
{ {