emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] trunk r116258: * keyboard.c (kbd_buffer_get_event): Read f


From: Michael Albinus
Subject: [Emacs-diffs] trunk r116258: * keyboard.c (kbd_buffer_get_event): Read file notification events
Date: Tue, 04 Feb 2014 11:40:41 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 116258
revision-id: address@hidden
parent: address@hidden
committer: Michael Albinus <address@hidden>
branch nick: trunk
timestamp: Tue 2014-02-04 12:40:31 +0100
message:
  * keyboard.c (kbd_buffer_get_event): Read file notification events
  also in batch mode.
  
  * xgselect.c (xg_select): Read glib events in any case, even if
  there are no file descriptors to watch for.  (Bug#16519)
modified:
  src/ChangeLog                  changelog-20091113204419-o5vbwnq5f7feedwu-1438
  src/keyboard.c                 keyboard.c-20091113204419-o5vbwnq5f7feedwu-449
  src/xgselect.c                 xgselect.c-20091121171556-bypaf8oo9ygoo13w-2
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog     2014-02-04 07:36:58 +0000
+++ b/src/ChangeLog     2014-02-04 11:40:31 +0000
@@ -1,3 +1,11 @@
+2014-02-04  Michael Albinus  <address@hidden>
+
+       * keyboard.c (kbd_buffer_get_event): Read file notification events
+       also in batch mode.
+
+       * xgselect.c (xg_select): Read glib events in any case, even if
+       there are no file descriptors to watch for.  (Bug#16519)
+
 2014-02-03  Martin Rudalics  <address@hidden>
 
        * dispextern.h (face_id): Add WINDOW_DIVIDER_FIRST_PIXEL_FACE_ID

=== modified file 'src/keyboard.c'
--- a/src/keyboard.c    2014-01-01 07:43:34 +0000
+++ b/src/keyboard.c    2014-02-04 11:40:31 +0000
@@ -3820,7 +3820,7 @@
     }
 #endif /* subprocesses */
 
-#ifndef HAVE_DBUS  /* We want to read D-Bus events in batch mode.  */
+#if !defined HAVE_DBUS && !defined USE_FILE_NOTIFY
   if (noninteractive
       /* In case we are running as a daemon, only do this before
         detaching from the terminal.  */
@@ -3831,7 +3831,7 @@
       *kbp = current_kboard;
       return obj;
     }
-#endif /* ! HAVE_DBUS  */
+#endif /* !defined HAVE_DBUS && !defined USE_FILE_NOTIFY  */
 
   /* Wait until there is input available.  */
   for (;;)

=== modified file 'src/xgselect.c'
--- a/src/xgselect.c    2014-01-01 07:43:34 +0000
+++ b/src/xgselect.c    2014-02-04 11:40:31 +0000
@@ -124,23 +124,19 @@
         }
     }
 
-  if (our_fds > 0 || (nfds == 0 && tmop == &tmo))
-    {
-
-      /* If Gtk+ is in use eventually gtk_main_iteration will be called,
-         unless retval is zero.  */
+  /* If Gtk+ is in use eventually gtk_main_iteration will be called,
+     unless retval is zero.  */
 #ifdef USE_GTK
-      if (retval == 0)
+  if (retval == 0)
 #endif
-        while (g_main_context_pending (context))
-          g_main_context_dispatch (context);
+    while (g_main_context_pending (context))
+      g_main_context_dispatch (context);
 
-      /* To not have to recalculate timeout, return like this.  */
-      if (retval == 0)
-        {
-          retval = -1;
-          errno = EINTR;
-        }
+  /* To not have to recalculate timeout, return like this.  */
+  if ((our_fds > 0 || (nfds == 0 && tmop == &tmo)) && (retval == 0))
+    {
+      retval = -1;
+      errno = EINTR;
     }
 
   return retval;


reply via email to

[Prev in Thread] Current Thread [Next in Thread]