bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#50043: 28.0.50; USABLE_SIGOI undef code paths do not work correctly


From: Ken Brown
Subject: bug#50043: 28.0.50; USABLE_SIGOI undef code paths do not work correctly
Date: Wed, 17 Nov 2021 09:25:30 -0500
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.3.1

On 11/17/2021 2:41 AM, Lars Ingebrigtsen wrote:
Ken Brown <kbrown@cornell.edu> writes:

Namely, whenever wait_reading_process_output is polling for input,
avoid getting stuck in select, something like this:

[...]

+#ifndef USABLE_SIGIO
+         /* If we're polling for input, don't get stuck in select for
+            more than 25 msec. */
+         struct timespec short_timeout = make_timespec (0, 25000000);
+         if ((read_kbd || !NILP (wait_for_cell))
+             && timespec_cmp (short_timeout, timeout) < 0)
+           timeout = short_timeout;
+#endif

Sounds like a good general solution to me (but I guess this will also
affect `accept-process-output'?  So it should probably be documented
there).

I don't think it affects accept-process-output. When the latter calls wait_reading_process_output, read_kbd == 0 and wait_for_cell == Qnil.

Ken





reply via email to

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