From 2c95d7776afe71a65a09976ae6f7e4705124da6e Mon Sep 17 00:00:00 2001
From: Chris Hanson <org/chris-hanson/cph>
Date: Thu, 12 Sep 1996 19:23:48 +0000
Subject: [PATCH] Patch X error handers so that they kill Scheme when the X
 connection is lost.  This is a kludge, but is needed to fix a common problem.

---
 v7/src/microcode/x11base.c | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/v7/src/microcode/x11base.c b/v7/src/microcode/x11base.c
index 1a9ac49bf..c8ddf571b 100644
--- a/v7/src/microcode/x11base.c
+++ b/v7/src/microcode/x11base.c
@@ -1,6 +1,6 @@
 /* -*-C-*-
 
-$Id: x11base.c,v 1.61 1995/09/27 16:21:46 cph Exp $
+$Id: x11base.c,v 1.62 1996/09/12 19:23:48 cph Exp $
 
 Copyright (c) 1989-95 Massachusetts Institute of Technology
 
@@ -262,7 +262,12 @@ static int
 DEFUN (x_io_error_handler, (display), Display * display)
 {
   fprintf (stderr, "\nX IO Error\n");
+  fflush (stderr);
+#if 0
   error_external_return ();
+#else
+  termination_eof ();
+#endif
 }
 
 static int
@@ -278,7 +283,11 @@ DEFUN (x_error_handler, (display, error_event),
 	   (error_event -> request_code));
   fprintf (stderr, "         Error serial: %x\n", (error_event -> serial));
   fflush (stderr);
+#if 0
   error_external_return ();
+#else
+  termination_eof ();
+#endif
 }
 
 typedef int EXFUN ((* x_error_handler_t), (Display *, XErrorEvent *));
-- 
2.25.1