summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2016-11-05 19:59:02 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2016-11-05 19:59:02 +0000
commitc5b4a474569def1097db8acf8c4c33ea0da3a589 (patch)
tree5e7e1c69be67806205bb5aa28abd3c20d6d80f3e
parentc21f9188ea97df8a40111abc8927b84a1901108a (diff)
One of the error paths would attempt to access not-yet-initialized locals.
Simply return since there is nothing more to do. Spotted by coverity. ok jsing@ beck@
-rw-r--r--lib/libssl/ssl_asn1.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libssl/ssl_asn1.c b/lib/libssl/ssl_asn1.c
index 59e7cdf7b25..02124da5204 100644
--- a/lib/libssl/ssl_asn1.c
+++ b/lib/libssl/ssl_asn1.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ssl_asn1.c,v 1.42 2016/11/04 15:09:29 jsing Exp $ */
+/* $OpenBSD: ssl_asn1.c,v 1.43 2016/11/05 19:59:01 miod Exp $ */
/*
* Copyright (c) 2016 Joel Sing <jsing@openbsd.org>
@@ -231,7 +231,7 @@ d2i_SSL_SESSION(SSL_SESSION **a, const unsigned char **pp, long length)
if (s == NULL) {
if ((s = SSL_SESSION_new()) == NULL) {
SSLerr(SSL_F_D2I_SSL_SESSION, ERR_R_MALLOC_FAILURE);
- goto err;
+ return (NULL);
}
}