diff options
Diffstat (limited to 'ext/openssl')
-rw-r--r-- | ext/openssl/ossl_ssl.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/openssl/ossl_ssl.c b/ext/openssl/ossl_ssl.c index d243b78dbb..cff32582ed 100644 --- a/ext/openssl/ossl_ssl.c +++ b/ext/openssl/ossl_ssl.c @@ -618,6 +618,7 @@ ossl_ssl_get_peer_cert_chain(VALUE self) return Qnil; } chain = SSL_get_peer_cert_chain(ssl); + if(!chain) return Qnil; num = sk_num(chain); ary = rb_ary_new2(num); for (i = 0; i < num; i++){ |