vcl/source/filter/imet/ios2met.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
New commits: commit f560a3a296871084801ced75fae20fb5f1b5d7ce Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Wed Sep 1 08:55:52 2021 +0100 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Wed Sep 1 22:10:20 2021 +0200 ofz: MemorySanitizer: use-of-uninitialized-value Change-Id: I481df54d421ad03813ba0755b735037e72d4c784 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121450 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> diff --git a/vcl/source/filter/imet/ios2met.cxx b/vcl/source/filter/imet/ios2met.cxx index 5be33dbc6f55..98b4c2bb82cc 100644 --- a/vcl/source/filter/imet/ios2met.cxx +++ b/vcl/source/filter/imet/ios2met.cxx @@ -1660,10 +1660,10 @@ void OS2METReader::ReadOrder(sal_uInt16 nOrderID, sal_uInt16 nOrderLen) OSPath* p=pPathList; pOS2MET->SeekRel(2); pOS2MET->ReadUInt32( nID ); - while (p!=nullptr && p->nID!=nID) - p=p->pSucc; + while (p && pOS2MET->good() && p->nID != nID) + p = p->pSucc; - if( p!=nullptr ) + if (p) { SetPen( aAttr.aLinCol, aAttr.nStrLinWidth, aAttr.eLinStyle ); SetRasterOp(aAttr.eLinMix);