Mercurial > hg > xemacs-beta
diff src/frame-x.c @ 3415:168e8d8a55be
[xemacs-hg @ 2006-05-22 22:07:05 by aidan]
Fix a hang in read-from-minibuffer if the X display disappears
author | aidan |
---|---|
date | Mon, 22 May 2006 22:07:07 +0000 |
parents | 374186f156d5 |
children | 3aab51033467 |
line wrap: on
line diff
--- a/src/frame-x.c Mon May 22 21:50:46 2006 +0000 +++ b/src/frame-x.c Mon May 22 22:07:07 2006 +0000 @@ -745,7 +745,14 @@ Bool y_position_specified_p = False; Bool internal_border_width_specified = False; Lisp_Object tail; - Widget w = FRAME_X_TEXT_WIDGET (f); + Widget w; + + /* We can be called after the X IO error handler has seen a broken pipe on + the relevant display. Don't do anything in that case. */ + if (!FRAME_LIVE_P (f) || DEVICE_X_BEING_DELETED (XDEVICE (FRAME_DEVICE (f)))) + return; + + w = FRAME_X_TEXT_WIDGET (f); for (tail = plist; !NILP (tail); tail = Fcdr (Fcdr (tail))) {