]> git.eshelyaron.com Git - emacs.git/commitdiff
(terminal-init-xterm): Experiment with a longer
authorDan Nicolaescu <dann@ics.uci.edu>
Tue, 23 Oct 2007 14:24:43 +0000 (14:24 +0000)
committerDan Nicolaescu <dann@ics.uci.edu>
Tue, 23 Oct 2007 14:24:43 +0000 (14:24 +0000)
timeout.

lisp/ChangeLog
lisp/term/xterm.el

index 406d29a2cc2d80dc3d7a4b769618c5878872c519..3364e892a4088cf945d164c64d28372021499e8d 100644 (file)
@@ -1,3 +1,8 @@
+2007-10-23  Dan Nicolaescu  <dann@ics.uci.edu>
+
+       * term/xterm.el (terminal-init-xterm): Experiment with a longer
+       timeout.
+
 2007-10-23  Katsumi Yamaoka  <yamaoka@jpl.org>
 
        * emacs-lisp/advice.el (ad-make-advised-docstring):
index a60aa90255f90363f9179f15366f7ff1b868abc9..fbc4c861bf973cdb3259c87fab55c5197dfedb69 100644 (file)
       (send-string-to-terminal "\e[>0c")
 
       ;; The reply should be of the form: \e [ > NUMBER1 ; NUMBER2 ; NUMBER3 c
-      (when (equal (read-event nil nil 0.1) ?\e)
-       (when (equal (read-event nil nil 0.1) ?\[)
-         (while (not (equal (setq chr (read-event nil nil 0.1)) ?c))
+      ;; If the timeout is completely removed for read-event, this
+      ;; might hang for terminals that pretend to be xterm, but don't
+      ;; respond to this escape sequence.  RMS' opinion was to remove
+      ;; it completely.  That might be right, but let's first try to
+      ;; see if by using a longer timeout we get rid of most issues.
+      (when (equal (read-event nil nil 2) ?\e)
+       (when (equal (read-event nil nil 2) ?\[)
+         (while (not (equal (setq chr (read-event nil nil 2)) ?c))
            (setq str (concat str (string chr))))
          (when (string-match ">0;\\([0-9]+\\);0" str)
            ;; NUMBER2 is the xterm version number, look for something