From 698143c53d1a1e4fe680b08c6a68ab327f4b6c5d Mon Sep 17 00:00:00 2001 From: miod <> Date: Fri, 18 Apr 2014 19:38:26 +0000 Subject: Shrink a local buffer to the size it really needs to be; this is the only discrepancy found while checking proper {HEX,DECIMAL}_SIZE macro usage, which is confusing enough. tweaks and ok jca@, ok guenther@ --- src/lib/libcrypto/objects/obj_dat.c | 2 +- src/lib/libssl/src/crypto/objects/obj_dat.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/lib/libcrypto/objects/obj_dat.c b/src/lib/libcrypto/objects/obj_dat.c index 641a97c8aa..cf4db7c6b5 100644 --- a/src/lib/libcrypto/objects/obj_dat.c +++ b/src/lib/libcrypto/objects/obj_dat.c @@ -469,7 +469,7 @@ int OBJ_obj2txt(char *buf, int buf_len, const ASN1_OBJECT *a, int no_name) BIGNUM *bl; unsigned long l; const unsigned char *p; - char tbuf[DECIMAL_SIZE(i)+DECIMAL_SIZE(l)+2]; + char tbuf[DECIMAL_SIZE(l) + 1]; if ((a == NULL) || (a->data == NULL)) { buf[0]='\0'; diff --git a/src/lib/libssl/src/crypto/objects/obj_dat.c b/src/lib/libssl/src/crypto/objects/obj_dat.c index 641a97c8aa..cf4db7c6b5 100644 --- a/src/lib/libssl/src/crypto/objects/obj_dat.c +++ b/src/lib/libssl/src/crypto/objects/obj_dat.c @@ -469,7 +469,7 @@ int OBJ_obj2txt(char *buf, int buf_len, const ASN1_OBJECT *a, int no_name) BIGNUM *bl; unsigned long l; const unsigned char *p; - char tbuf[DECIMAL_SIZE(i)+DECIMAL_SIZE(l)+2]; + char tbuf[DECIMAL_SIZE(l) + 1]; if ((a == NULL) || (a->data == NULL)) { buf[0]='\0'; -- cgit v1.2.3-55-g6feb