]> git.eshelyaron.com Git - emacs.git/commitdiff
Avoid selecting for excessive output configuration events
authorPo Lu <luangruo@yahoo.com>
Thu, 8 Sep 2022 05:20:33 +0000 (13:20 +0800)
committerPo Lu <luangruo@yahoo.com>
Thu, 8 Sep 2022 05:20:33 +0000 (13:20 +0800)
* src/xterm.c (x_term_init): Only select for
RROutputPropertyNotify if GTK is in use.  Emacs doesn't need it
itself, and output property changes will otherwise lead to 2
second freezes over connections with high network latency.

src/xterm.c

index 6f76622bfe2424996fa90d806ca357c615488f60..aa3fb0fc124c7a992bf7a75afb707f064e8b3ea3 100644 (file)
@@ -28742,10 +28742,13 @@ x_term_init (Lisp_Object display_name, char *xrm_option, char *resource_name)
                          (RRScreenChangeNotifyMask
                           | RRCrtcChangeNotifyMask
                           | RROutputChangeNotifyMask
-                          /* Emacs doesn't actually need this, but GTK
-                             selects for it when the display is
+#ifdef USE_GTK
+                          /* Emacs doesn't actually need this, but
+                             GTK selects for it when the display is
                              initialized.  */
-                          | RROutputPropertyNotifyMask));
+                          | RROutputPropertyNotifyMask
+#endif
+                          ));
 
          dpyinfo->last_monitor_attributes_list
            = Fx_display_monitor_attributes_list (term);