crypto/sm2/sm2_sign.c: ensure UINT16_MAX is properly defined
[openssl.git] / crypto / bio / bss_conn.c
index c87b431cdb0f878c9f6a06c75886bd4d833ba510..e9673fe783369308316b07231c232f052dade344 100644 (file)
@@ -223,8 +223,10 @@ BIO_CONNECT *BIO_CONNECT_new(void)
 {
     BIO_CONNECT *ret;
 
-    if ((ret = OPENSSL_zalloc(sizeof(*ret))) == NULL)
+    if ((ret = OPENSSL_zalloc(sizeof(*ret))) == NULL) {
+        BIOerr(BIO_F_BIO_CONNECT_NEW, ERR_R_MALLOC_FAILURE);
         return NULL;
+    }
     ret->state = BIO_CONN_S_BEFORE;
     ret->connect_family = BIO_FAMILY_IPANY;
     return ret;