diff options
author | Tomas Mraz <tmraz@fedoraproject.org> | 2019-04-03 19:07:00 +0200 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2019-04-16 10:55:36 +0100 |
commit | 4912bf74280caa7aec5b206e29b103d594075123 (patch) | |
tree | bcfb89b50bdde7c4c6fd339bd79b4d86edd728f3 /crypto/bio/bss_mem.c | |
parent | 27a11cd60270091f38e432aca5d46744ee66503d (diff) |
Add testing of RDONLY memory BIOs
Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/8649)
(cherry picked from commit d34bce03acc53c583df954bbed65d4800751563a)
Diffstat (limited to 'crypto/bio/bss_mem.c')
-rw-r--r-- | crypto/bio/bss_mem.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/crypto/bio/bss_mem.c b/crypto/bio/bss_mem.c index abf0f04111..8c621d6c1e 100644 --- a/crypto/bio/bss_mem.c +++ b/crypto/bio/bss_mem.c @@ -204,6 +204,7 @@ static int mem_read(BIO *b, char *out, int outl) if ((out != NULL) && (ret > 0)) { memcpy(out, bm->data, ret); bm->length -= ret; + bm->max -= ret; bm->data += ret; } else if (bm->length == 0) { ret = b->num; |