* [PATCH] dskqxs: fix loop to allow `next'
@ 2022-10-11 0:05 Eric Wong
0 siblings, 0 replies; only message in thread
From: Eric Wong @ 2022-10-11 0:05 UTC (permalink / raw)
To: meta
`do {} while(...)' loops in Perl don't support `next', actually :x
This only affects *BSD platforms with IO::KQueue installed.
Fixes: d6674af04cb74a4e "httpd|nntpd: avoid missed signal wakeups"
---
lib/PublicInbox/DSKQXS.pm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/PublicInbox/DSKQXS.pm b/lib/PublicInbox/DSKQXS.pm
index eccfa56d..7141b131 100644
--- a/lib/PublicInbox/DSKQXS.pm
+++ b/lib/PublicInbox/DSKQXS.pm
@@ -71,7 +71,7 @@ sub READ { # called by sysread() for signalfd compatibility
my $nr = $len / 128;
my $r = 0;
$_[1] = '';
- do {
+ while (1) {
while ($nr--) {
my $signo = shift(@$sigbuf) or last;
# caller only cares about signalfd_siginfo.ssi_signo:
@@ -94,7 +94,7 @@ sub READ { # called by sysread() for signalfd compatibility
# field shows coalesced signals, and maybe we'll use it
# in the future...
@$sigbuf = map { $_->[0] } @events;
- } while (1);
+ }
}
# for fileno() calls in PublicInbox::DS
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2022-10-11 0:06 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-11 0:05 [PATCH] dskqxs: fix loop to allow `next' Eric Wong
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).