Ticket #8476: 8476.diff
File 8476.diff, 1.1 KB (added by , 16 years ago) |
---|
-
http.php
673 673 $meta = stream_get_meta_data($handle); 674 674 $theHeaders = $meta['wrapper_data']; 675 675 } else { 676 if( ! isset( $http_response_header ) ) 677 global $http_response_header; 676 678 $theHeaders = $http_response_header; 677 679 } 678 680 … … 793 795 794 796 $strResponse = stream_get_contents($handle); 795 797 $meta = stream_get_meta_data($handle); 798 var_dump($meta['wrapper_data']); 796 799 $processedHeaders = WP_Http::processHeaders($meta['wrapper_data']); 797 800 798 801 if ( ! empty( $strResponse ) && isset( $processedHeaders['headers']['transfer-encoding'] ) && 'chunked' == $processedHeaders['headers']['transfer-encoding'] ) … … 1031 1034 return new WP_Error('http_request_failed', $curl_error); 1032 1035 if ( in_array( curl_getinfo( $handle, CURLINFO_HTTP_CODE ), array(301, 302) ) ) 1033 1036 return new WP_Error('http_request_failed', __('Too many redirects.')); 1034 1037 1035 1038 $theHeaders = array( 'headers' => array() ); 1036 1039 $theBody = ''; 1037 1040 }