[Libreoffice-commits] core.git: writerfilter/source
Caolán McNamara
caolanm at redhat.com
Wed Sep 7 07:29:50 UTC 2016
writerfilter/source/rtftok/rtftokenizer.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 4349b6b060c95ca42f5a2ecebafe389e0e9dbb48
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Sep 6 20:19:04 2016 +0100
rtf: don't skip backwards on skipping bin specified bytes
otherwise we could end up re-parsing the block endlessly
Change-Id: Ia90a9e5b513951c91e1917483f9e030dbee98ffb
Reviewed-on: https://gerrit.libreoffice.org/28707
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/writerfilter/source/rtftok/rtftokenizer.cxx b/writerfilter/source/rtftok/rtftokenizer.cxx
index 4b7f76c..5afceab 100644
--- a/writerfilter/source/rtftok/rtftokenizer.cxx
+++ b/writerfilter/source/rtftok/rtftokenizer.cxx
@@ -283,7 +283,7 @@ RTFError RTFTokenizer::dispatchKeyword(OString& rKeyword, bool bParam, int nPara
{
// skip binary data explicitely, to not trip over rtf markup
// control characters
- if (rKeyword.equals("bin"))
+ if (rKeyword.equals("bin") && nParam > 0)
Strm().SeekRel(nParam);
return RTFError::OK;
}
More information about the Libreoffice-commits
mailing list