summaryrefslogtreecommitdiff
path: root/lisp/term
diff options
context:
space:
mode:
authorKarl Heuer <kwzh@gnu.org>1994-10-24 23:30:14 +0000
committerKarl Heuer <kwzh@gnu.org>1994-10-24 23:30:14 +0000
commitf1b648d6d0a8a9a26a50d077715689430f3bb8a7 (patch)
tree7e41e8ca3aeceedee0e01c49d50c817190b9c646 /lisp/term
parentb8c70430de7dada8e7e18c4f56fd983cb9f25d41 (diff)
downloademacs-f1b648d6d0a8a9a26a50d077715689430f3bb8a7.tar.gz
Make previous change conditional.
Diffstat (limited to 'lisp/term')
-rw-r--r--lisp/term/x-win.el17
1 files changed, 12 insertions, 5 deletions
diff --git a/lisp/term/x-win.el b/lisp/term/x-win.el
index 07db0c5aa65..9752dc16364 100644
--- a/lisp/term/x-win.el
+++ b/lisp/term/x-win.el
@@ -624,11 +624,18 @@ This is in addition to the primary selection.")
(while (setq i (string-match "[.*]" x-resource-name))
(aset x-resource-name i ?-))))
-(x-open-connection (or x-display-name
- (setq x-display-name (getenv "DISPLAY")))
- x-command-line-resources
- ;; Exit Emacs with fatal error if this fails.
- t)
+;; For the benefit of older Emacses (19.27 and earlier) that are sharing
+;; the same lisp directory, don't pass the third argument unless we seem
+;; to have the multi-display support.
+(if (fboundp 'x-close-connection)
+ (x-open-connection (or x-display-name
+ (setq x-display-name (getenv "DISPLAY")))
+ x-command-line-resources
+ ;; Exit Emacs with fatal error if this fails.
+ t)
+ (x-open-connection (or x-display-name
+ (setq x-display-name (getenv "DISPLAY")))
+ x-command-line-resources))
(setq frame-creation-function 'x-create-frame-with-faces)