From e85c40a3f7ee0361ff6b92d8a7485629e70a5043 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Sat, 5 Apr 2014 12:45:15 +0000 Subject: [PATCH] Avoid an undefined index notice in wp_http_validate_url(). props jesin. fixes #27684. Built from https://develop.svn.wordpress.org/trunk@27953 git-svn-id: http://core.svn.wordpress.org/trunk@27783 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/http.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-includes/http.php b/wp-includes/http.php index 0b4b109d9f..57746ff802 100644 --- a/wp-includes/http.php +++ b/wp-includes/http.php @@ -510,7 +510,7 @@ function wp_http_validate_url( $url ) { if ( 80 === $port || 443 === $port || 8080 === $port ) return $url; - if ( $parsed_home && $same_host && $parsed_home['port'] === $port ) + if ( $parsed_home && $same_host && isset( $parsed_home['port'] ) && $parsed_home['port'] === $port ) return $url; return false;