summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--crypto/evp/bio_b64.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/crypto/evp/bio_b64.c b/crypto/evp/bio_b64.c
index cade6f8f95..e70fc322d8 100644
--- a/crypto/evp/bio_b64.c
+++ b/crypto/evp/bio_b64.c
@@ -289,6 +289,14 @@ static int b64_read(BIO *b, char *out, int outl)
(unsigned char *)ctx->tmp, i);
ctx->tmp_len = 0;
}
+ /*
+ * If eof or an error was signalled, then the condition
+ * 'ctx->cont <= 0' will prevent b64_read() from reading
+ * more data on subsequent calls. This assignment was
+ * deleted accidentally in commit 5562cfaca4f3.
+ */
+ ctx->cont = i;
+
ctx->buf_off = 0;
if (i < 0) {
ret_code = 0;