summaryrefslogtreecommitdiffstats
path: root/ssl/ssl_lib.c
diff options
context:
space:
mode:
authorBodo Möller <bodo@openssl.org>1999-08-02 22:09:23 +0200
committerBodo Möller <bodo@openssl.org>1999-08-02 22:09:23 +0200
commitf3e67ac1bc9f27f24d2deae0fe97142988ef6bff (patch)
tree0d4429adb3846058748d0752ef8623c56409f9c3 /ssl/ssl_lib.c
parentavoid cast (diff)
downloadopenssl-f3e67ac1bc9f27f24d2deae0fe97142988ef6bff.tar.xz
openssl-f3e67ac1bc9f27f24d2deae0fe97142988ef6bff.zip
fix previous modification -- if ssl->cert is NULL, don't follow the pointer.
Diffstat (limited to 'ssl/ssl_lib.c')
-rw-r--r--ssl/ssl_lib.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c
index 0b30ccf918..72b7e3aa4e 100644
--- a/ssl/ssl_lib.c
+++ b/ssl/ssl_lib.c
@@ -575,6 +575,8 @@ int SSL_check_private_key(SSL *ssl)
SSLerr(SSL_F_SSL_CHECK_PRIVATE_KEY,ERR_R_PASSED_NULL_PARAMETER);
return(0);
}
+ if (ssl->cert == NULL)
+ return 0;
if (ssl->cert->key->x509 == NULL)
{
SSLerr(SSL_F_SSL_CHECK_PRIVATE_KEY,SSL_R_NO_CERTIFICATE_ASSIGNED);