diff options
author | Mikhail Voytenko <mav@openoffice.org> | 2010-04-08 10:20:00 +0200 |
---|---|---|
committer | Mikhail Voytenko <mav@openoffice.org> | 2010-04-08 10:20:00 +0200 |
commit | dfb38daff2b625d51bef0dfdffdf732dad39c2da (patch) | |
tree | e66b2148a7701e5a76431e4a32a17a56202bec29 /oox | |
parent | 683ee9d13de3ea385e53443b7291137f02e51ebd (diff) |
fwk138: #161971# open the OpOfXML documents in repair mode always
Diffstat (limited to 'oox')
-rw-r--r-- | oox/source/helper/zipstorage.cxx | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/oox/source/helper/zipstorage.cxx b/oox/source/helper/zipstorage.cxx index c90b2071b133..032ae0c589f8 100644 --- a/oox/source/helper/zipstorage.cxx +++ b/oox/source/helper/zipstorage.cxx @@ -63,10 +63,15 @@ ZipStorage::ZipStorage( /* #i105325# ::comphelper::OStorageHelper::GetStorageFromInputStream() cannot be used here as it will open a storage with format type 'PackageFormat' that will not work with OOXML packages. + + #161971# The MS-document storages should always be opened in Repair-Mode to + ignore the format errors and get so much info as possible. I hate this + solution, but it seems to be the only consistent way to handle the MS-documents. + TODO: #i105410# switch to 'OFOPXMLFormat' and use its implementation of relations handling. */ mxStorage = ::comphelper::OStorageHelper::GetStorageOfFormatFromInputStream( - ZIP_STORAGE_FORMAT_STRING, rxInStream, rxFactory ); + ZIP_STORAGE_FORMAT_STRING, rxInStream, rxFactory, sal_True ); } catch( Exception& ) { @@ -84,7 +89,7 @@ ZipStorage::ZipStorage( { using namespace ::com::sun::star::embed::ElementModes; mxStorage = ::comphelper::OStorageHelper::GetStorageOfFormatFromStream( - OFOPXML_STORAGE_FORMAT_STRING, rxStream, READWRITE | TRUNCATE, rxFactory ); + OFOPXML_STORAGE_FORMAT_STRING, rxStream, READWRITE | TRUNCATE, rxFactory, sal_True ); } catch( Exception& ) { |