summaryrefslogtreecommitdiff
path: root/vcl/unx/generic/app
diff options
context:
space:
mode:
Diffstat (limited to 'vcl/unx/generic/app')
-rw-r--r--vcl/unx/generic/app/saldata.cxx25
1 files changed, 11 insertions, 14 deletions
diff --git a/vcl/unx/generic/app/saldata.cxx b/vcl/unx/generic/app/saldata.cxx
index f02a25b0d532..9b1b9def7fbe 100644
--- a/vcl/unx/generic/app/saldata.cxx
+++ b/vcl/unx/generic/app/saldata.cxx
@@ -313,22 +313,19 @@ int X11SalData::XErrorHdl( Display *pDisplay, XErrorEvent *pEvent )
int X11SalData::XIOErrorHdl( Display * )
{
- if (::osl::Thread::getCurrentIdentifier() != Application::GetMainThreadIdentifier())
+ if (::osl::Thread::getCurrentIdentifier() == Application::GetMainThreadIdentifier())
{
- pthread_exit(NULL);
- return 0;
+ /* #106197# hack: until a real shutdown procedure exists
+ * _exit ASAP
+ */
+ if( ImplGetSVData()->maAppData.mbAppQuit )
+ _exit(1);
+
+ // really bad hack
+ if( ! SessionManagerClient::checkDocumentsSaved() )
+ /* oslSignalAction eToDo = */ osl_raiseSignal (OSL_SIGNAL_USER_X11SUBSYSTEMERROR, NULL);
}
- /* #106197# hack: until a real shutdown procedure exists
- * _exit ASAP
- */
- if( ImplGetSVData()->maAppData.mbAppQuit )
- _exit(1);
-
- // really bad hack
- if( ! SessionManagerClient::checkDocumentsSaved() )
- /* oslSignalAction eToDo = */ osl_raiseSignal (OSL_SIGNAL_USER_X11SUBSYSTEMERROR, NULL);
-
std::fprintf( stderr, "X IO Error\n" );
std::fflush( stdout );
std::fflush( stderr );
@@ -337,7 +334,7 @@ int X11SalData::XIOErrorHdl( Display * )
* do apply here. Since there is nothing to be done after an XIO
* error we have to _exit immediately.
*/
- _exit(0);
+ _exit(1);
return 0;
}