From 6905ab05e647bd3379cca26c824e9ecd44942240 Mon Sep 17 00:00:00 2001 From: guenther <> Date: Sun, 20 Apr 2014 20:06:20 +0000 Subject: Restore beck's (void)snprintf(): they were reviewed. --- src/lib/libcrypto/x509/by_dir.c | 2 +- src/lib/libcrypto/x509/x509_txt.c | 4 ++-- src/lib/libcrypto/x509v3/v3_alt.c | 4 ++-- src/lib/libssl/src/crypto/x509/by_dir.c | 2 +- src/lib/libssl/src/crypto/x509/x509_txt.c | 4 ++-- src/lib/libssl/src/crypto/x509v3/v3_alt.c | 4 ++-- 6 files changed, 10 insertions(+), 10 deletions(-) (limited to 'src/lib') diff --git a/src/lib/libcrypto/x509/by_dir.c b/src/lib/libcrypto/x509/by_dir.c index 295389bcb3..fdfca6140a 100644 --- a/src/lib/libcrypto/x509/by_dir.c +++ b/src/lib/libcrypto/x509/by_dir.c @@ -336,7 +336,7 @@ get_cert_by_subject(X509_LOOKUP *xl, int type, X509_NAME *name, hent = NULL; } for (;;) { - snprintf(b->data, b->max, "%s/%08lx.%s%d", + (void) snprintf(b->data, b->max, "%s/%08lx.%s%d", ent->dir, h, postfix, k); #ifndef OPENSSL_NO_POSIX_IO diff --git a/src/lib/libcrypto/x509/x509_txt.c b/src/lib/libcrypto/x509/x509_txt.c index 31a909a12c..3fb3b12355 100644 --- a/src/lib/libcrypto/x509/x509_txt.c +++ b/src/lib/libcrypto/x509/x509_txt.c @@ -184,7 +184,7 @@ X509_verify_cert_error_string(long n) return("CRL path validation error"); default: - snprintf(buf, sizeof buf, "error number %ld", n); - return (buf); + (void) snprintf(buf, sizeof buf, "error number %ld", n); + return(buf); } } diff --git a/src/lib/libcrypto/x509v3/v3_alt.c b/src/lib/libcrypto/x509v3/v3_alt.c index 95b1fa4c97..636677df94 100644 --- a/src/lib/libcrypto/x509v3/v3_alt.c +++ b/src/lib/libcrypto/x509v3/v3_alt.c @@ -143,14 +143,14 @@ STACK_OF(CONF_VALUE) *i2v_GENERAL_NAME(X509V3_EXT_METHOD *method, case GEN_IPADD: p = gen->d.ip->data; if(gen->d.ip->length == 4) - snprintf(oline, sizeof oline, + (void) snprintf(oline, sizeof oline, "%d.%d.%d.%d", p[0], p[1], p[2], p[3]); else if(gen->d.ip->length == 16) { oline[0] = 0; for (i = 0; i < 8; i++) { - snprintf(htmp, sizeof htmp, + (void) snprintf(htmp, sizeof htmp, "%X", p[0] << 8 | p[1]); p += 2; strlcat(oline, htmp, sizeof(oline)); diff --git a/src/lib/libssl/src/crypto/x509/by_dir.c b/src/lib/libssl/src/crypto/x509/by_dir.c index 295389bcb3..fdfca6140a 100644 --- a/src/lib/libssl/src/crypto/x509/by_dir.c +++ b/src/lib/libssl/src/crypto/x509/by_dir.c @@ -336,7 +336,7 @@ get_cert_by_subject(X509_LOOKUP *xl, int type, X509_NAME *name, hent = NULL; } for (;;) { - snprintf(b->data, b->max, "%s/%08lx.%s%d", + (void) snprintf(b->data, b->max, "%s/%08lx.%s%d", ent->dir, h, postfix, k); #ifndef OPENSSL_NO_POSIX_IO diff --git a/src/lib/libssl/src/crypto/x509/x509_txt.c b/src/lib/libssl/src/crypto/x509/x509_txt.c index 31a909a12c..3fb3b12355 100644 --- a/src/lib/libssl/src/crypto/x509/x509_txt.c +++ b/src/lib/libssl/src/crypto/x509/x509_txt.c @@ -184,7 +184,7 @@ X509_verify_cert_error_string(long n) return("CRL path validation error"); default: - snprintf(buf, sizeof buf, "error number %ld", n); - return (buf); + (void) snprintf(buf, sizeof buf, "error number %ld", n); + return(buf); } } diff --git a/src/lib/libssl/src/crypto/x509v3/v3_alt.c b/src/lib/libssl/src/crypto/x509v3/v3_alt.c index 95b1fa4c97..636677df94 100644 --- a/src/lib/libssl/src/crypto/x509v3/v3_alt.c +++ b/src/lib/libssl/src/crypto/x509v3/v3_alt.c @@ -143,14 +143,14 @@ STACK_OF(CONF_VALUE) *i2v_GENERAL_NAME(X509V3_EXT_METHOD *method, case GEN_IPADD: p = gen->d.ip->data; if(gen->d.ip->length == 4) - snprintf(oline, sizeof oline, + (void) snprintf(oline, sizeof oline, "%d.%d.%d.%d", p[0], p[1], p[2], p[3]); else if(gen->d.ip->length == 16) { oline[0] = 0; for (i = 0; i < 8; i++) { - snprintf(htmp, sizeof htmp, + (void) snprintf(htmp, sizeof htmp, "%X", p[0] << 8 | p[1]); p += 2; strlcat(oline, htmp, sizeof(oline)); -- cgit v1.2.3-55-g6feb