summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--desktop/inc/app.hxx3
-rw-r--r--desktop/inc/strings.hrc1
-rw-r--r--desktop/source/app/app.cxx9
3 files changed, 12 insertions, 1 deletions
diff --git a/desktop/inc/app.hxx b/desktop/inc/app.hxx
index 3372e751dbf1..9d6ac9864a52 100644
--- a/desktop/inc/app.hxx
+++ b/desktop/inc/app.hxx
@@ -58,7 +58,8 @@ class Desktop final : public Application
BE_LANGUAGE_MISSING,
BE_USERINSTALL_NOTENOUGHDISKSPACE,
BE_USERINSTALL_NOWRITEACCESS,
- BE_OFFICECONFIG_BROKEN
+ BE_OFFICECONFIG_BROKEN,
+ BE_2NDOFFICE_WITHCAT,
};
enum BootstrapStatus
{
diff --git a/desktop/inc/strings.hrc b/desktop/inc/strings.hrc
index b18117bb5a0d..f4af7ad24602 100644
--- a/desktop/inc/strings.hrc
+++ b/desktop/inc/strings.hrc
@@ -163,6 +163,7 @@
#define STR_BOOTSTRAP_ERR_LANGUAGE_MISSING NC_("STR_BOOTSTRAP_ERR_LANGUAGE_MISSING", "The user interface language cannot be determined.")
#define STR_BOOTSTRAP_ERR_USERINSTALL_FAILED NC_("STR_BOOTSTRAP_ERR_USERINSTALL_FAILED", "User installation could not be completed. ")
#define STR_BOOTSTRAP_ERR_NO_CFG_SERVICE NC_("STR_BOOTSTRAP_ERR_NO_CFG_SERVICE", "The configuration service is not available.")
+#define STR_BOOTSTRAP_ERR_2NDOFFICE_WITHCAT NC_("STR_BOOTSTRAP_ERR_2NDOFFICE_WITHCAT", "There is already another %PRODUCTNAME instance running. Please close all %PRODUCTNAME processes before running with the '--cat' or '--script-cat' option.")
#define STR_ASK_START_SETUP_MANUALLY NC_("STR_ASK_START_SETUP_MANUALLY", "Start the setup application to repair the installation from the CD or the folder containing the installation packages.")
#define STR_CONFIG_ERR_ACCESS_GENERAL NC_("STR_CONFIG_ERR_ACCESS_GENERAL", "A general error occurred while accessing your central configuration. ")
#define STR_LO_MUST_BE_RESTARTED NC_("STR_LO_MUST_BE_RESTARTED", "%PRODUCTNAME must unfortunately be manually restarted once after installation or update." )
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index e4058bfe8932..cb3beaf0ae26 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -523,6 +523,10 @@ void Desktop::Init()
else if ( aStatus == RequestHandler::IPC_STATUS_2ND_OFFICE )
{
// 2nd office startup should terminate after sending cmdlineargs through pipe
+ if (rCmdLineArgs.IsTextCat() || rCmdLineArgs.IsScriptCat())
+ {
+ HandleBootstrapErrors( BE_2NDOFFICE_WITHCAT, OUString() );
+ }
SetBootstrapStatus(BS_TERMINATE);
}
else if ( !rCmdLineArgs.GetUnknown().isEmpty()
@@ -880,6 +884,11 @@ void Desktop::HandleBootstrapErrors(
FatalError(MakeStartupErrorMessage(aDiagnosticMessage));
}
+ else if ( aBootstrapError == BE_2NDOFFICE_WITHCAT )
+ {
+ OUString aDiagnosticMessage = DpResId(STR_BOOTSTRAP_ERR_2NDOFFICE_WITHCAT);
+ FatalError(MakeStartupErrorMessage(aDiagnosticMessage));
+ }
}