diff options
Diffstat (limited to 'oox/source')
-rw-r--r-- | oox/source/helper/attributelist.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/oox/source/helper/attributelist.cxx b/oox/source/helper/attributelist.cxx index 40bc8f31c243..183794263ef0 100644 --- a/oox/source/helper/attributelist.cxx +++ b/oox/source/helper/attributelist.cxx @@ -228,6 +228,10 @@ sal_Int32 AttributeList::getToken( sal_Int32 nAttrToken, sal_Int32 nDefault ) co OUString AttributeList::getString( sal_Int32 nAttrToken, const OUString& rDefault ) const { + // try to avoid slow exception throw/catch if we can + if (rDefault.isEmpty()) + return mxAttribs->getOptionalValue( nAttrToken ); + try { return mxAttribs->getValue( nAttrToken ); |