summaryrefslogtreecommitdiff
path: root/vcl/unx/gtk/app/gtkdata.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'vcl/unx/gtk/app/gtkdata.cxx')
-rw-r--r--vcl/unx/gtk/app/gtkdata.cxx12
1 files changed, 5 insertions, 7 deletions
diff --git a/vcl/unx/gtk/app/gtkdata.cxx b/vcl/unx/gtk/app/gtkdata.cxx
index 14a19495b22a..2f7cc3f9d638 100644
--- a/vcl/unx/gtk/app/gtkdata.cxx
+++ b/vcl/unx/gtk/app/gtkdata.cxx
@@ -519,14 +519,12 @@ GtkData::GtkData( SalInstance *pInstance )
XIOErrorHandler aOrigXIOErrorHandler = NULL;
-int XIOErrorHdl(Display *pDisplay)
+int XIOErrorHdl(Display *)
{
- if (::osl::Thread::getCurrentIdentifier() != Application::GetMainThreadIdentifier())
- {
- pthread_exit(NULL);
- return 0;
- }
- return aOrigXIOErrorHandler ? aOrigXIOErrorHandler(pDisplay) : 0;
+ fprintf(stderr, "X IO Error\n");
+ _exit(1);
+ // avoid crashes in unrelated threads that still run while atexit
+ // handlers are in progress
}
GtkData::~GtkData()