summaryrefslogtreecommitdiff
path: root/fpicker/source/office/iodlg.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'fpicker/source/office/iodlg.cxx')
-rw-r--r--fpicker/source/office/iodlg.cxx13
1 files changed, 12 insertions, 1 deletions
diff --git a/fpicker/source/office/iodlg.cxx b/fpicker/source/office/iodlg.cxx
index f1e2132d5c37..cd9a53a0cc88 100644
--- a/fpicker/source/office/iodlg.cxx
+++ b/fpicker/source/office/iodlg.cxx
@@ -833,7 +833,18 @@ void SvtFileDialog::OpenHdl_Impl(void const * pVoid)
{
case FILEDLG_MODE_SAVE:
{
- if ( ::utl::UCBContentHelper::Exists( aFileObj.GetMainURL( INetURLObject::DecodeMechanism::NONE ) ) )
+ bool exists;
+ try
+ {
+ exists = utl::UCBContentHelper::Exists( aFileObj.GetMainURL( INetURLObject::DecodeMechanism::NONE ) );
+ }
+ catch (const Exception&)
+ {
+ DBG_UNHANDLED_EXCEPTION("fpicker.office");
+ ErrorHandler::HandleError(ERRCODE_IO_GENERAL);
+ return;
+ }
+ if (exists)
{
OUString aMsg = FpsResId(STR_SVT_ALREADYEXISTOVERWRITE);
aMsg = aMsg.replaceFirst(