OSSL_HTTP_REQ_CTX_nbio(): fix copy&paste glitch calling BIO_should_retry(rctx-rbio)
authorDr. David von Oheimb <David.von.Oheimb@siemens.com>
Tue, 28 Jun 2022 09:51:32 +0000 (11:51 +0200)
committerHugo Landau <hlandau@openssl.org>
Wed, 6 Jul 2022 07:24:07 +0000 (08:24 +0100)
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Hugo Landau <hlandau@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/18674)

(cherry picked from commit 059a4ad0999dd6dbd7340b5e4f7566812d51bb1e)

crypto/http/http_client.c

index 48a2e12976f5d15563c3e334fd49e0fbe45a7f9a..aa76ca1972eafbb7d2c8d81b7cc1cb8d57b2d14b 100644 (file)
@@ -567,7 +567,7 @@ int OSSL_HTTP_REQ_CTX_nbio(OSSL_HTTP_REQ_CTX *rctx)
         if (rctx->req != NULL && !BIO_eof(rctx->req)) {
             n = BIO_read(rctx->req, rctx->buf, rctx->buf_size);
             if (n <= 0) {
-                if (BIO_should_retry(rctx->rbio))
+                if (BIO_should_retry(rctx->req))
                     return -1;
                 ERR_raise(ERR_LIB_HTTP, HTTP_R_FAILED_READING_DATA);
                 return 0;