X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/1c09677af04c9e37714e09b73eb9dbc5b2e3eb13..refs/tags/wordpress-3.0.2-scripts:/wp-includes/class-IXR.php diff --git a/wp-includes/class-IXR.php b/wp-includes/class-IXR.php index f8d61fe8..49f80b0c 100644 --- a/wp-includes/class-IXR.php +++ b/wp-includes/class-IXR.php @@ -356,7 +356,7 @@ EOD; $args = $args[0]; } // Are we dealing with a function or a method? - if (substr($method, 0, 5) == 'this:') { + if ( is_string( $method ) && substr($method, 0, 5) == 'this:' ) { // It's a class method - check it exists $method = substr($method, 5); if (!method_exists($this, $method)) { @@ -581,7 +581,8 @@ class IXR_Client { $gettingHeaders = false; } if (!$gettingHeaders) { - $contents .= trim($line); + // WP#12559 remove trim so as to not strip newlines from received response. + $contents .= $line; } if ($this->debug) { $debug_contents .= $line;