Make WordPress Core

Changeset 10282


Ignore:
Timestamp:
12/30/2008 10:53:35 PM (16 years ago)
Author:
ryan
Message:

Chunked decode fixes. Don't return WP_Error for body. Props jacobsantos. see #8618

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/http.php

    r10281 r10282  
    99 * @package WordPress
    1010 * @subpackage HTTP
    11  * @since 2.7
     11 * @since 2.7.0
    1212 * @author Jacob Santos <wordpress@santosj.name>
    1313 */
     
    4242 * @package WordPress
    4343 * @subpackage HTTP
    44  * @since 2.7
     44 * @since 2.7.0
    4545 */
    4646class WP_Http {
     
    4949     * PHP4 style Constructor - Calls PHP5 Style Constructor
    5050     *
    51      * @since 2.7
     51     * @since 2.7.0
    5252     * @return WP_Http
    5353     */
     
    6565     * the overhead should be fine.
    6666     *
    67      * @since 2.7
     67     * @since 2.7.0
    6868     * @return WP_Http
    6969     */
     
    9191     * has failed to respond."
    9292     *
    93      * @since 2.7
     93     * @since 2.7.0
    9494     * @access private
    9595     *
     
    142142     * is addressed here, by just not including that transport.
    143143     *
    144      * @since 2.7
     144     * @since 2.7.0
    145145     * @access private
    146146     *
     
    217217     *
    218218     * @access public
    219      * @since 2.7
     219     * @since 2.7.0
    220220     *
    221221     * @param string $url URI resource.
     
    296296     *
    297297     * @access public
    298      * @since 2.7
     298     * @since 2.7.0
    299299     *
    300300     * @param string $url URI resource.
     
    314314     *
    315315     * @access public
    316      * @since 2.7
     316     * @since 2.7.0
    317317     *
    318318     * @param string $url URI resource.
     
    332332     *
    333333     * @access public
    334      * @since 2.7
     334     * @since 2.7.0
    335335     *
    336336     * @param string $url URI resource.
     
    349349     * @access public
    350350     * @static
    351      * @since 2.7
     351     * @since 2.7.0
    352352     *
    353353     * @param string $strResponse The full response string
     
    368368     * @access public
    369369     * @static
    370      * @since 2.7
     370     * @since 2.7.0
    371371     *
    372372     * @param string|array $headers
     
    409409     * @todo Add support for footer chunked headers.
    410410     * @access public
    411      * @since 2.7
     411     * @since 2.7.0
    412412     * @static
    413413     *
     
    450450                return $body;
    451451            }
    452         } while ( false === $done );
     452        } while ( true === $done );
    453453    }
    454454}
     
    462462 * @package WordPress
    463463 * @subpackage HTTP
    464  * @since 2.7
     464 * @since 2.7.0
    465465 */
    466466class WP_Http_Fsockopen {
     
    606606     * Whether this class can be used for retrieving an URL.
    607607     *
    608      * @since 2.7
     608     * @since 2.7.0
    609609     * @static
    610610     * @return boolean False means this class can not be used, true means it can.
     
    630630 * @package WordPress
    631631 * @subpackage HTTP
    632  * @since 2.7
     632 * @since 2.7.0
    633633 */
    634634class WP_Http_Fopen {
     
    644644     *
    645645     * @access public
    646      * @since 2.7
     646     * @since 2.7.0
    647647     *
    648648     * @param string $url URI resource.
     
    716716     * Whether this class can be used for retrieving an URL.
    717717     *
     718     * @since 2.7.0
    718719     * @static
    719720     * @return boolean False means this class can not be used, true means it can.
     
    737738 * @package WordPress
    738739 * @subpackage HTTP
    739  * @since 2.7
     740 * @since 2.7.0
    740741 */
    741742class WP_Http_Streams {
     
    744745     *
    745746     * @access public
    746      * @since 2.7
     747     * @since 2.7.0
    747748     *
    748749     * @param string $url
     
    840841     * @static
    841842     * @access public
    842      * @since 2.7
     843     * @since 2.7.0
    843844     *
    844845     * @return boolean False means this class can not be used, true means it can.
     
    865866 * @package WordPress
    866867 * @subpackage HTTP
    867  * @since 2.7
     868 * @since 2.7.0
    868869 */
    869870class WP_Http_ExtHTTP {
     
    955956     *
    956957     * @static
    957      * @since 2.7
     958     * @since 2.7.0
    958959     *
    959960     * @return boolean False means this class can not be used, true means it can.
     
    981982     *
    982983     * @access public
    983      * @since 2.7
     984     * @since 2.7.0
    984985     *
    985986     * @param string $url
     
    10821083     *
    10831084     * @static
    1084      * @since 2.7
     1085     * @since 2.7.0
    10851086     *
    10861087     * @return boolean False means this class can not be used, true means it can.
     
    10971098 * Returns the initialized WP_Http Object
    10981099 *
    1099  * @since 2.7
     1100 * @since 2.7.0
    11001101 * @access private
    11011102 *
     
    11481149 * @see wp_remote_request() For more information on the response array format.
    11491150 *
    1150  * @since 2.7
     1151 * @since 2.7.0
    11511152 *
    11521153 * @param string $url Site URL to retrieve.
     
    11651166 * @see wp_remote_request() For more information on the response array format.
    11661167 *
    1167  * @since 2.7
     1168 * @since 2.7.0
    11681169 *
    11691170 * @param string $url Site URL to retrieve.
     
    11811182 * @see wp_remote_request() For more information on the response array format.
    11821183 *
    1183  * @since 2.7
     1184 * @since 2.7.0
    11841185 *
    11851186 * @param string $url Site URL to retrieve.
     
    11951196 * Retrieve only the headers from the raw response.
    11961197 *
    1197  * @since 2.7
     1198 * @since 2.7.0
    11981199 *
    11991200 * @param array $response HTTP response.
     
    12101211 * Retrieve a single header by name from the raw response.
    12111212 *
    1212  * @since 2.7
     1213 * @since 2.7.0
    12131214 *
    12141215 * @param array $response
     
    12311232 * Will return an empty array if incorrect parameter value is given.
    12321233 *
    1233  * @since 2.7
     1234 * @since 2.7.0
    12341235 *
    12351236 * @param array $response HTTP response.
     
    12481249 * Will return an empty array if incorrect parameter value is given.
    12491250 *
    1250  * @since 2.7
     1251 * @since 2.7.0
    12511252 *
    12521253 * @param array $response HTTP response.
     
    12631264 * Retrieve only the body from the raw response.
    12641265 *
    1265  * @since 2.7
     1266 * @since 2.7.0
    12661267 *
    12671268 * @param array $response HTTP response.
Note: See TracChangeset for help on using the changeset viewer.