summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@suse.com>2012-02-24 14:22:54 +0000
committerMichael Meeks <michael.meeks@suse.com>2012-02-24 16:46:47 +0000
commit1543f1ec6deba898f71b04d242af8bed74dcd8d6 (patch)
tree9fa2f45a8f1eb040358d5755f1feaa6f97255827
parent1dc601f1b62485e50fe43a8037aa5eb59c60cfe9 (diff)
basic: tolerate empty / missing dialog.xlc and script.xlc files
-rw-r--r--basic/source/uno/namecont.cxx15
1 files changed, 1 insertions, 14 deletions
diff --git a/basic/source/uno/namecont.cxx b/basic/source/uno/namecont.cxx
index a76ff93faf39..fbc52eaf176e 100644
--- a/basic/source/uno/namecont.cxx
+++ b/basic/source/uno/namecont.cxx
@@ -765,19 +765,14 @@ void SfxLibraryContainer::init_Impl( const OUString& rInitialDocumentURL,
try
{
xInput = mxSFI->openFileRead( aFileName );
}
catch(const Exception& )
{
+ // Silently tolerate empty or missing files
xInput.clear();
- if( nPass == 0 )
- {
- SfxErrorContext aEc( ERRCTX_SFX_LOADBASIC, aFileName );
- sal_uIntPtr nErrorCode = ERRCODE_IO_GENERAL;
- ErrorHandler::HandleError( nErrorCode );
- }
}
// Old variant?
if( !xInput.is() && nPass == 0 )
{
INetURLObject aLibInfoInetObj( String(maLibraryPath).GetToken(1) );
@@ -790,15 +785,12 @@ void SfxLibraryContainer::init_Impl( const OUString& rInitialDocumentURL,
xInput = mxSFI->openFileRead( aFileName );
mbOldInfoFormat = true;
}
catch(const Exception& )
{
xInput.clear();
- SfxErrorContext aEc( ERRCTX_SFX_LOADBASIC, aFileName );
- sal_uIntPtr nErrorCode = ERRCODE_IO_GENERAL;
- ErrorHandler::HandleError( nErrorCode );
}
}
delete pLibInfoInetObj;
}
@@ -954,17 +946,12 @@ void SfxLibraryContainer::init_Impl( const OUString& rInitialDocumentURL,
// Keep flag for documents to force writing the new index files
if( !bStorage )
mbOldInfoFormat = sal_False;
delete pLibArray;
}
- // Only in the first pass it's an error when no index file is found
- else if( nPass == 0 )
- {
- return;
- }
}
// #110009: END Scope to force the StorageRefs to be destructed
}
if( !bStorage && meInitMode == DEFAULT )