From: Daniel Lowrey Date: Thu, 5 Mar 2015 06:00:59 +0000 (-0700) Subject: Merge branch 'PHP-5.6' X-Git-Tag: PRE_PHP7_NSAPI_REMOVAL~814 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=fe29b8134cbacf6ca07e948be4fe66813817cdad;p=php Merge branch 'PHP-5.6' * PHP-5.6: hexadecimal is case*in*sensitive Conflicts: ext/openssl/xp_ssl.c --- fe29b8134cbacf6ca07e948be4fe66813817cdad diff --cc ext/openssl/xp_ssl.c index 20ebda2336,4786974239..3fad16ee02 --- a/ext/openssl/xp_ssl.c +++ b/ext/openssl/xp_ssl.c @@@ -306,15 -268,15 +306,15 @@@ static int verify_callback(int preverif } /* }}} */ -static int php_x509_fingerprint_cmp(X509 *peer, const char *method, const char *expected TSRMLS_DC) +static int php_x509_fingerprint_cmp(X509 *peer, const char *method, const char *expected) { - char *fingerprint; - int fingerprint_len; + zend_string *fingerprint; int result = -1; - if (php_openssl_x509_fingerprint(peer, method, 0, &fingerprint, &fingerprint_len TSRMLS_CC) == SUCCESS) { - result = strcasecmp(expected, fingerprint); - efree(fingerprint); + fingerprint = php_openssl_x509_fingerprint(peer, method, 0); + if (fingerprint) { - result = strcmp(expected, fingerprint->val); ++ result = strcasecmp(expected, fingerprint->val); + zend_string_release(fingerprint); } return result;