aboutsummaryrefslogtreecommitdiff
path: root/src/stable
diff options
context:
space:
mode:
Diffstat (limited to 'src/stable')
-rw-r--r--src/stable/myriad.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/stable/myriad.cpp b/src/stable/myriad.cpp
index 03cffa9..5e511fd 100644
--- a/src/stable/myriad.cpp
+++ b/src/stable/myriad.cpp
@@ -768,9 +768,7 @@ int32_t Bu::Myriad::Stream::read( int32_t iStart, void *pTarget,
768 768
769 if( iStart+iSize >= this->iSize ) 769 if( iStart+iSize >= this->iSize )
770 { 770 {
771 int32_t iDiff = (iStart+iSize)-this->iSize; 771 iSize = this->iSize-iStart;
772 iSize -= iDiff;
773 iStart += iDiff;
774 } 772 }
775 773
776 while( iSize > 0 ) 774 while( iSize > 0 )