summaryrefslogtreecommitdiff
path: root/svtools
diff options
context:
space:
mode:
Diffstat (limited to 'svtools')
-rw-r--r--svtools/source/dialogs/restartdialog.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/svtools/source/dialogs/restartdialog.cxx b/svtools/source/dialogs/restartdialog.cxx
index 47a3ee906091..1de2e09cc014 100644
--- a/svtools/source/dialogs/restartdialog.cxx
+++ b/svtools/source/dialogs/restartdialog.cxx
@@ -94,9 +94,12 @@ void svtools::executeRestartDialog(
css::uno::Reference< css::uno::XComponentContext > const & context,
weld::Window* parent, RestartReason reason)
{
+ auto xRestartManager = css::task::OfficeRestartManager::get(context);
+ if (xRestartManager->isRestartRequested(false))
+ return; // don't try to show another dialog when restart is already in progress
RestartDialog aDlg(parent, reason);
if (aDlg.run()) {
- css::task::OfficeRestartManager::get(context)->requestRestart(
+ xRestartManager->requestRestart(
css::uno::Reference< css::task::XInteractionHandler >());
}
}