diff options
author | Hugo Landau <hlandau@openssl.org> | 2022-11-22 13:29:45 +0000 |
---|---|---|
committer | Hugo Landau <hlandau@openssl.org> | 2023-01-19 13:17:39 +0000 |
commit | af8b52cffe303c41510d1228605f9fcff9af0ee3 (patch) | |
tree | 24fd67dfc2dce93d18e3c748722d42b29bb2f290 /ssl | |
parent | e30c502ae930295b889cce7375a83a8c742c68b4 (diff) |
QUIC Front-End I/O API: Fix WANT_READ signalling for SSL_read
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19734)
Diffstat (limited to 'ssl')
-rw-r--r-- | ssl/quic/quic_impl.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/ssl/quic/quic_impl.c b/ssl/quic/quic_impl.c index c5490cd075..d6c9116497 100644 --- a/ssl/quic/quic_impl.c +++ b/ssl/quic/quic_impl.c @@ -1131,9 +1131,12 @@ static int quic_read(SSL *s, void *buf, size_t len, size_t *bytes_read, int peek else return QUIC_RAISE_NON_NORMAL_ERROR(qc, ERR_R_INTERNAL_ERROR, NULL); } - } - return 1; + return 1; + } else { + /* We did not get any bytes and are not in blocking mode. */ + return QUIC_RAISE_NORMAL_ERROR(qc, SSL_ERROR_WANT_READ); + } } int ossl_quic_read(SSL *s, void *buf, size_t len, size_t *bytes_read) |