Skip to content

Commit a140e61

Browse files
committed
PHPC-1031: Add ASN1_STRING_get0_data check for config.w32 too
1 parent f46d222 commit a140e61

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

config.w32

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,11 @@ if (PHP_MONGODB != "no") {
170170
/* PHP 7.1.2 introduced SETUP_OPENSSL(), which supports OpenSSL 1.1.x. Earlier
171171
* versions will use the legacy check for OpenSSL 1.0.x and lower. */
172172
if (typeof SETUP_OPENSSL === 'function') {
173-
mongoc_ssl_found = SETUP_OPENSSL("mongodb", mongoc_ssl_path_to_check) > 0;
173+
openssl_type = SETUP_OPENSSL("mongodb", mongoc_ssl_path_to_check);
174+
mongoc_ssl_found = openssl_type > 0;
175+
if (openssl_type >= 2) {
176+
mongoc_opts.MONGOC_HAVE_ASN1_STRING_GET0_DATA = 1;
177+
}
174178
} else if (CHECK_LIB("ssleay32.lib", "mongodb", mongoc_ssl_path_to_check) &&
175179
CHECK_LIB("libeay32.lib", "mongodb", mongoc_ssl_path_to_check) &&
176180
CHECK_LIB("crypt32.lib", "mongodb", mongoc_ssl_path_to_check) &&

0 commit comments

Comments
 (0)