]> git.eshelyaron.com Git - emacs.git/commitdiff
Don't start both timerfd and alarms on Cygwin
authorKen Brown <kbrown@cornell.edu>
Thu, 11 Nov 2021 20:09:24 +0000 (15:09 -0500)
committerKen Brown <kbrown@cornell.edu>
Fri, 12 Nov 2021 20:04:49 +0000 (15:04 -0500)
* src/atimer.c (set_alarm) [CYGWIN]: Don't start both timerfd and
alarms; this causes a slowdown.  (Bug#51734)

src/atimer.c

index 490c21bff16f93f200a074cf61b33686c541bc6b..9bde9c2446f5d304f30fe8927cb1cacc2314f934 100644 (file)
@@ -316,6 +316,13 @@ set_alarm (void)
              exit = true;
            }
 # endif
+
+# ifdef CYGWIN
+         /* Don't start both timerfd and alarms on Cygwin; this
+            causes a slowdown (bug#51734). */
+         if (exit)
+           return;
+# endif
          if (alarm_timer_ok
              && timer_settime (alarm_timer, TIMER_ABSTIME, &ispec, 0) == 0)
            exit = true;