[Libreoffice-commits] core.git: svtools/source
Caolán McNamara
caolanm at redhat.com
Wed Nov 8 11:16:44 UTC 2017
svtools/source/svrtf/parrtf.cxx | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
New commits:
commit 8fc98bb35b38da07018de1dcaa39be419019b5e6
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Nov 8 09:14:31 2017 +0000
ofz#4113 Null-dereference READ
Change-Id: If586bd265e323b5c2a308c2e853456c2778e8cb0
Reviewed-on: https://gerrit.libreoffice.org/44448
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/svtools/source/svrtf/parrtf.cxx b/svtools/source/svrtf/parrtf.cxx
index bcdb67b4600e..a29e571383b9 100644
--- a/svtools/source/svrtf/parrtf.cxx
+++ b/svtools/source/svrtf/parrtf.cxx
@@ -159,9 +159,11 @@ int SvRTFParser::GetNextToken_()
if( 0 <= nTokenValue )
{
nUCharOverread = (sal_uInt8)nTokenValue;
- //cmc: other ifdef breaks #i3584
- aParserStates.top().
- nUCharOverread = nUCharOverread;
+ if (!aParserStates.empty())
+ {
+ //cmc: other ifdef breaks #i3584
+ aParserStates.top().nUCharOverread = nUCharOverread;
+ }
}
aToken.clear(); // #i47831# erase token to prevent the token from being treated as text
// read next token
More information about the Libreoffice-commits
mailing list