summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorJan Holesovsky <kendy@collabora.com>2016-01-14 11:52:18 +0100
committerJan Holesovsky <kendy@collabora.com>2016-01-14 11:58:11 +0100
commit83c540d275e351b1979f7b59be8aad728bca6dc0 (patch)
tree09e6eb2043dda48366395da1b7754129f97327cd /sfx2
parentd8c69d313b717c5dcf158e8a9d1a9c8497ab8a68 (diff)
sfx2: Convert the exception to one that we actually announce.
Otherwise saving to a non-existing http:// URL leads to a crash. Change-Id: Ia4b49e2872616545dcedb2fc5553cf5a20a1f97d
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/doc/sfxbasemodel.cxx11
1 files changed, 10 insertions, 1 deletions
diff --git a/sfx2/source/doc/sfxbasemodel.cxx b/sfx2/source/doc/sfxbasemodel.cxx
index 20f15ee6aec2..ccdd99b16fd5 100644
--- a/sfx2/source/doc/sfxbasemodel.cxx
+++ b/sfx2/source/doc/sfxbasemodel.cxx
@@ -1699,7 +1699,16 @@ void SAL_CALL SfxBaseModel::storeToURL( const OUString& rURL
{
m_pData->m_pObjectShell->AddLog( OUString( OSL_LOG_PREFIX "storeToURL" ) );
SfxSaveGuard aSaveGuard(this, m_pData, false);
- impl_store( rURL, rArgs, true );
+ try {
+ impl_store(rURL, rArgs, true);
+ }
+ catch (const uno::Exception &e)
+ {
+ // convert to the exception we announce in the throw
+ // (eg. neon likes to throw InteractiveAugmentedIOException which
+ // is not an io::IOException)
+ throw io::IOException(e.Message, e.Context);
+ }
}
}