diff options
author | sb <sb@openoffice.org> | 2010-07-28 13:01:55 +0200 |
---|---|---|
committer | sb <sb@openoffice.org> | 2010-07-28 13:01:55 +0200 |
commit | de9172871b29cea2fddbce9d5c55730f6d64754b (patch) | |
tree | 2e4feff3daf259e59143f81fca51e9675d09349a /configmgr | |
parent | 85a4e97dc97a88c59ab0cf8a4d89d9f9413adf9f (diff) |
fwk152: #i113454# accept broken .xcs files containing empty <oor:component-scheme>
Diffstat (limited to 'configmgr')
-rw-r--r-- | configmgr/source/xcsparser.cxx | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/configmgr/source/xcsparser.cxx b/configmgr/source/xcsparser.cxx index 79e122759fc8..37b46494c6a7 100644 --- a/configmgr/source/xcsparser.cxx +++ b/configmgr/source/xcsparser.cxx @@ -321,15 +321,19 @@ void XcsParser::endElement(XmlReader const & reader) { } else { switch (state_) { case STATE_COMPONENT_SCHEMA: + // To support old, broken extensions with .xcs files that contain + // empty <component-schema> elements: + state_ = STATE_COMPONENT_DONE; + break; + case STATE_TEMPLATES: + state_ = STATE_TEMPLATES_DONE; + break; case STATE_TEMPLATES_DONE: throw css::uno::RuntimeException( (rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("no component element in ")) + reader.getUrl()), css::uno::Reference< css::uno::XInterface >()); - case STATE_TEMPLATES: - state_ = STATE_TEMPLATES_DONE; - break; case STATE_COMPONENT_DONE: break; default: |