From: Richard Levitte Date: Mon, 4 Nov 2002 11:30:38 +0000 (+0000) Subject: Off-by-one-error corrected. X-Git-Tag: OpenSSL_0_9_7-beta4~88 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=455bacd4d33d51ca428e31bd9b00f9ae78fdc381;p=oweals%2Fopenssl.git Off-by-one-error corrected. PR: 235 --- diff --git a/crypto/cryptlib.c b/crypto/cryptlib.c index bd49ad0693..0849245924 100644 --- a/crypto/cryptlib.c +++ b/crypto/cryptlib.c @@ -461,7 +461,7 @@ const char *CRYPTO_get_lock_name(int type) return("dynamic"); else if (type < CRYPTO_NUM_LOCKS) return(lock_names[type]); - else if (type-CRYPTO_NUM_LOCKS >= sk_num(app_locks)) + else if (type-CRYPTO_NUM_LOCKS > sk_num(app_locks)) return("ERROR"); else return(sk_value(app_locks,type-CRYPTO_NUM_LOCKS));