Fixed address family test error for AF_UNIX in BIO_ADDR_make
authorZhu Qun-Ying <zhu.qunying@gmail.com>
Wed, 30 Aug 2017 21:52:50 +0000 (14:52 -0700)
committerRichard Levitte <levitte@openssl.org>
Thu, 31 Aug 2017 09:43:54 +0000 (11:43 +0200)
CLA: trivial

Reviewed-by: Rich Salz <rsalz@openssl.org>
Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4298)

crypto/bio/b_addr.c

index b2cd83c3929a78b94518bd3a5e7f5a5bdcf9bdbd..ba26c9144af271feeea6438d233d744d2915e1bc 100644 (file)
@@ -76,7 +76,7 @@ int BIO_ADDR_make(BIO_ADDR *ap, const struct sockaddr *sa)
     }
 #endif
 #ifdef AF_UNIX
-    if (ap->sa.sa_family == AF_UNIX) {
+    if (sa->sa_family == AF_UNIX) {
         ap->s_un = *(const struct sockaddr_un *)sa;
         return 1;
     }