CLEANUP: http-ana: Remove useless if statement about L7 retries

Thanks to the commit 1f08bffe0 ("MINOR: http-ana: Perform L7 retries because
of status codes in response analyser"), the L7 retries about the response
status code is now fully handled in the HTTP response analyser.
CF_READ_ERROR flag is no longer set on the response channel in this
case. Thus it is useless to try to catch L7 retries when CF_READ_ERROR is
set because it cannot happen.

The above commit was backported to 2.4, thus this one should also be
backported.
This commit is contained in:
Christopher Faulet 2021-05-31 11:45:24 +02:00
parent 476462010e
commit 1a4449b0d0

View File

@ -1368,18 +1368,6 @@ int http_wait_for_response(struct stream *s, struct channel *rep, int an_bit)
if (objt_cs(s->si[1].end))
conn = objt_cs(s->si[1].end)->conn;
if (si_b->flags & SI_FL_L7_RETRY &&
(!conn || conn->err_code != CO_ER_SSL_EARLY_FAILED)) {
/* If we arrive here, then CF_READ_ERROR was
* set by si_cs_recv() because we matched a
* status, otherwise it would have removed
* the SI_FL_L7_RETRY flag, so it's ok not
* to check s->be->retry_type.
*/
if (co_data(rep) || do_l7_retry(s, si_b) == 0)
return 0;
}
/* Perform a L7 retry because server refuses the early data. */
if ((si_b->flags & SI_FL_L7_RETRY) &&
(s->be->retry_type & PR_RE_EARLY_ERROR) &&