From 12cee37632412b68373c2a9b64af1f1c6efd7a1a Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Sat, 1 Nov 2003 14:35:14 +0000 Subject: [PATCH] Changes for the new setFilePointer2() semantic. --- aviclasses/AVIReadHandler.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/aviclasses/AVIReadHandler.cpp b/aviclasses/AVIReadHandler.cpp index e63cbf11d..5b294c888 100644 --- a/aviclasses/AVIReadHandler.cpp +++ b/aviclasses/AVIReadHandler.cpp @@ -1497,7 +1497,7 @@ void AVIReadHandler::_parseFile(List2& streamlist) { } if (dwLength) { - if (m_pInput->setFilePointer2(dwLength + (dwLength&1), seek_current) == -1) + if (!m_pInput->setFilePointer2(dwLength + (dwLength&1), seek_current)) break; } @@ -1627,11 +1627,11 @@ terminate_scan: break; if (fccType2 != formtypeAVIEXTENDED && fccType2 != listtypeAVIMOVIE) { - if (m_pInput->setFilePointer2(dwLength + (dwLength&1) - 4, seek_current) == -1) + if (!m_pInput->setFilePointer2(dwLength + (dwLength&1) - 4, seek_current)) break; } } else { - if (m_pInput->setFilePointer2(dwLength + (dwLength&1), seek_current) == -1) + if (!m_pInput->setFilePointer2(dwLength + (dwLength&1), seek_current)) break; } } @@ -1840,7 +1840,7 @@ bool AVIReadHandler::_parseStreamHeader(List2& streamlist, uint32 } if (dwLength) { - if (m_pInput->setFilePointer2(dwLength + (dwLength&1), seek_current) == -1) + if (!m_pInput->setFilePointer2(dwLength + (dwLength&1), seek_current)) break; } } @@ -2440,7 +2440,7 @@ long AVIReadHandler::ReadData(int stream, void *buffer, sint64 position, long le // _RPT3(0,"Reading from file %d, position %I64x, size %d\n", nCurrentFile, position, len); - if (m_pInput->setFilePointer2(position & _LL(0x0000FFFFFFFFFFFF), seek_beginning) == -1) + if (!m_pInput->setFilePointer2(position & _LL(0x0000FFFFFFFFFFFF), seek_beginning)) return -1; return m_pInput->read(buffer, len); }