[openssl-commits] [openssl] master update
Rich Salz
rsalz at openssl.org
Sun Apr 26 17:12:39 UTC 2015
The branch master has been updated
via 88806cfc611935981e3752dccda1685022be2e2b (commit)
from 2f58faad668ee1b4270611d6548c9fbe78589fe6 (commit)
- Log -----------------------------------------------------------------
commit 88806cfc611935981e3752dccda1685022be2e2b
Author: Rich Salz <rsalz at akamai.com>
Date: Sun Apr 26 13:12:04 2015 -0400
Fix main build breakage.
A variable declaration got dropped during a merge.
And if a compiler inlines strcmp() and you put a strcmp in an
assert message, the resultant stringification exceeds ANSI string
limits.
Reviewed-by: Viktor Dukhovni <viktor at openssl.org>
-----------------------------------------------------------------------
Summary of changes:
apps/ocsp.c | 1 +
apps/opt.c | 9 +++++----
2 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/apps/ocsp.c b/apps/ocsp.c
index c58cd44..d22ce7d 100644
--- a/apps/ocsp.c
+++ b/apps/ocsp.c
@@ -222,6 +222,7 @@ int ocsp_main(int argc, char **argv)
STACK_OF(OCSP_CERTID) *ids = NULL;
STACK_OF(OPENSSL_STRING) *reqnames = NULL;
STACK_OF(X509) *sign_other = NULL, *verify_other = NULL, *rother = NULL;
+ STACK_OF(X509) *issuers = NULL;
X509 *issuer = NULL, *cert = NULL, *rca_cert = NULL;
X509 *signer = NULL, *rsigner = NULL;
X509_STORE *store = NULL;
diff --git a/apps/opt.c b/apps/opt.c
index 3706739..df2bea5 100644
--- a/apps/opt.c
+++ b/apps/opt.c
@@ -171,7 +171,7 @@ char *opt_init(int ac, char **av, const OPTIONS *o)
for (; o->name; ++o) {
const OPTIONS *next;
#ifndef NDEBUG
- int i;
+ int duplicated, i;
#endif
if (o->name == OPT_HELP_STR || o->name == OPT_MORE_STR)
@@ -188,11 +188,12 @@ char *opt_init(int ac, char **av, const OPTIONS *o)
|| i == 'f' || i == 'F');
/* Make sure there are no duplicates. */
- for (next = o; (++next)->name;) {
+ for (next = o + 1; next->name; ++next) {
/*
- * do allow aliases: assert(o->retval != next->retval);
+ * Some compilers inline strcmp and the assert string is too long.
*/
- assert(strcmp(o->name, next->name) != 0);
+ duplicated = strcmp(o->name, next->name) == 0;
+ assert(!duplicated);
}
#endif
if (o->name[0] == '\0') {
More information about the openssl-commits
mailing list