From: claudio Date: Sun, 23 Jan 2022 11:59:40 +0000 (+0000) Subject: On poll() failure we want to skip pollfd related action but the signal X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=62af241786ef4955a5ec8d1dc7a1b246d65fac5e;p=openbsd On poll() failure we want to skip pollfd related action but the signal delivery checks at the end still need to happen. So that on EINTR bgpd processes reconfigure or mrt files ASAP. Fix for mrt integration tests. Reported by and ok anton@ --- diff --git a/usr.sbin/bgpd/bgpd.c b/usr.sbin/bgpd/bgpd.c index 537d491b142..e2b77b737d1 100644 --- a/usr.sbin/bgpd/bgpd.c +++ b/usr.sbin/bgpd/bgpd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bgpd.c,v 1.240 2022/01/20 18:06:20 claudio Exp $ */ +/* $OpenBSD: bgpd.c,v 1.241 2022/01/23 11:59:40 claudio Exp $ */ /* * Copyright (c) 2003, 2004 Henning Brauer @@ -350,7 +350,7 @@ BROKEN if (pledge("stdio rpath wpath cpath fattr unix route recvfd sendfd", log_warn("poll error"); quit = 1; } - continue; + goto next_loop; } if (handle_pollfd(&pfd[PFD_PIPE_SESSION], ibuf_se) == -1) { @@ -403,6 +403,7 @@ BROKEN if (pledge("stdio rpath wpath cpath fattr unix route recvfd sendfd", if (pfd[i].revents != 0) bgpd_rtr_connect_done(pfd[i].fd, conf); + next_loop: if (reconfig) { u_int error;