Revert "BUG/MINOR: checks: do not uselessly poll for reads before the connection...
authorVincent Bernat <vincent@bernat.ch>
Wed, 18 Sep 2019 06:01:20 +0000 (08:01 +0200)
committerVincent Bernat <bernat@debian.org>
Wed, 18 Sep 2019 06:02:53 +0000 (07:02 +0100)
This reverts commit ab160a47acde9dc9c341b328c8716a721a389ab4.

Gbp-Pq: Name 0001-Revert-BUG-MINOR-checks-do-not-uselessly-poll-for-re.patch

src/checks.c

index 7b55abda597614951409d4ba17071cee355ae730..bf1a8c944d57971c4ff9931062df49dce8cd4715 100644 (file)
@@ -1447,12 +1447,8 @@ static int wake_srv_chk(struct conn_stream *cs)
                ret = tcpcheck_main(check);
                cs = check->cs;
                conn = cs->conn;
-       } else {
-               if (!(check->wait_list.events & SUB_RETRY_SEND))
-                       __event_srv_chk_w(cs);
-               if (!(check->wait_list.events & SUB_RETRY_RECV))
-                       __event_srv_chk_r(cs);
-       }
+       } else if (!(check->wait_list.events & SUB_RETRY_SEND))
+               __event_srv_chk_w(cs);
 
        if (unlikely(conn->flags & CO_FL_ERROR || cs->flags & CS_FL_ERROR)) {
                /* We may get error reports bypassing the I/O handlers, typically
@@ -2262,9 +2258,7 @@ static struct task *process_chk_conn(struct task *t, void *context, unsigned sho
                                 * sending since otherwise we won't be woken up.
                                 */
                                __event_srv_chk_w(cs);
-                               if (!(conn->flags & CO_FL_WAIT_L4_CONN) ||
-                                   !(check->wait_list.events & SUB_RETRY_SEND))
-                                       __event_srv_chk_r(cs);
+                               __event_srv_chk_r(cs);
                        }
 
                        task_set_affinity(t, tid_bit);