summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2019-11-21 12:17:04 +0000
committerCaolán McNamara <caolanm@redhat.com>2019-11-21 14:29:27 +0100
commit14d6a07abd7685d8867731938d4c8c3483672909 (patch)
tree6c30fa45a246a784ab7736e4e1363e05fcf8372d
parent2c4218069429df3e5cb26edc6ec3163f71a942ed (diff)
ofz#19034 fix ~infinite loop
Change-Id: Ibc90b3b68a55f8396fbe623eb0db6c289fe978a1 Reviewed-on: https://gerrit.libreoffice.org/83383 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--filter/source/msfilter/msdffimp.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx
index ebe405aefb9d..10a0ca1f6382 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -6241,7 +6241,7 @@ bool SvxMSDffManager::GetShapeContainerData( SvStream& rSt,
// search for the Blip Property!
sal_uLong nPropRead = 0;
nLenShapePropTbl = nLength;
- long nStartShapePropTbl = rSt.Tell();
+ auto nStartShapePropTbl = rSt.Tell();
do
{
sal_uInt16 nPropId(0);
@@ -6324,7 +6324,7 @@ bool SvxMSDffManager::GetShapeContainerData( SvStream& rSt,
break;
}
}
- while( nPropRead < nLenShapePropTbl );
+ while (rSt.good() && nPropRead < nLenShapePropTbl);
rSt.Seek( nStartShapePropTbl + nLenShapePropTbl );
nReadSpCont += nLenShapePropTbl;
}