summaryrefslogtreecommitdiff
path: root/desktop/source/app/sofficemain.cxx
diff options
context:
space:
mode:
authorTor Lillqvist <tml@iki.fi>2013-03-12 13:43:31 +0200
committerTor Lillqvist <tml@iki.fi>2013-03-12 13:47:33 +0200
commitecdd44e8f577e51e0208e9f421704a70041f1be8 (patch)
tree5dff0ddfe4796f698065d7346e0febff7882c778 /desktop/source/app/sofficemain.cxx
parent0950bb5e9cb85265986435fe26906af9741f2854 (diff)
Use symbolic names instead of magic literal constants
We use tons of plain C-style #defines to give symbolic names to constants all over the place already, in headers used from C++ code only. So why in this rare case where the symbolic names for some constants actually would be needed from a C source file, too, here then we define them inside a C++ class? Change-Id: I45726fe42687779724c45a1e2b118cc7a1debcf1
Diffstat (limited to 'desktop/source/app/sofficemain.cxx')
-rw-r--r--desktop/source/app/sofficemain.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/desktop/source/app/sofficemain.cxx b/desktop/source/app/sofficemain.cxx
index 8a0f6985c47e..a8c091177171 100644
--- a/desktop/source/app/sofficemain.cxx
+++ b/desktop/source/app/sofficemain.cxx
@@ -22,6 +22,7 @@
#include "desktopdllapi.h"
#include "app.hxx"
+#include "exithelper.h"
#include "cmdlineargs.hxx"
#include "cmdlinehelp.hxx"
@@ -100,7 +101,8 @@ Java_org_libreoffice_experimental_desktop_Desktop_runMain(JNIEnv* /* env */,
do {
nRet = soffice_main();
LOGI("soffice_main returned %d", nRet );
- } while (nRet == 81 || nRet == 79); // pretend to re-start.
+ } while (nRet == EXITHELPER_NORMAL_RESTART ||
+ nRet == EXITHELPER_CRASH_WITH_RESTART); // pretend to re-start.
}