From a697a60bfdc99199dc60abe49b9791bdc6cb06d3 Mon Sep 17 00:00:00 2001 From: John Safranek Date: Fri, 18 May 2012 10:06:06 -0700 Subject: [PATCH] fixed a bounds check error --- src/ocsp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ocsp.c b/src/ocsp.c index 3422c5aa6..0434649d6 100644 --- a/src/ocsp.c +++ b/src/ocsp.c @@ -261,7 +261,7 @@ static byte* decode_http_response(byte* httpBuf, int httpBufSz, int* ocspRespSz) int len = 0; idx += 15; if (buf[idx] == ' ') idx++; - while (buf[idx] > '0' && buf[idx] < '9' && idx < httpBufSz) { + while (buf[idx] >= '0' && buf[idx] <= '9' && idx < httpBufSz) { len = (len * 10) + (buf[idx] - '0'); idx++; }