Opened 16 years ago
Closed 16 years ago
#10163 closed defect (bug) (fixed)
HTTP request API error
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 2.9 | Priority: | normal |
Severity: | normal | Version: | 2.8 |
Component: | HTTP API | Keywords: | has-patch tested commit |
Focuses: | Cc: |
Description
When I try to use the function 'fech_rss' with a RSS2.0 feed I get this error:
Warning: gzinflate() [function.gzinflate]: data error in xxxxxx/wp-includes/http.php on line 1787
With other formats (RSS0.92, RSS1.0, Atom, etc) there is no problem
Sample feed to play: http://ws.audioscrobbler.com/1.0/user/Ryck/recenttracks.rss
Prior to WP2.8 there wasn't any error...
Attachments (1)
Change History (11)
#2
@
16 years ago
- Keywords has-patch needs-testing added; http gzinflate removed
attachment 10163.diff added
- Introduces a compatible_gzinflate() function which attempts to decode most of the odd deflated string types which servers may return.
- PHP's inbuilt function cannot handle many servers when they return data with different headers.
- Works with the example link provided above, Not tested with any other servers.
#5
@
16 years ago
- Keywords tested commit added; needs-testing removed
Was getting this error while using the plugins_api().
Applied the patch on 2.8.1-beta2 and the warning dissapeared.
#7
@
16 years ago
Works fine for me with 2.8.1.
Do you mean, That the patch works under 2.8.1 for you? Have you tested on many url's, or just not found one that fails? :)
#8
@
16 years ago
I applied the patch to my installation, which is 2.8.1 with a couple of plugins. Before the patch, I saw the same error message as the reporter when using the LastFM plugin. However, the decompression was successful, only the error messages were annoying. Suppressing these error messages by putting an @ before gzinflate worked as well, but this seems to be a better solution.
After applying the patch, I haven't seen any error messages nor malfunctions. The only problem I found occurs with curl and open_basedir enabled, then WP doesn't follow redirects. However, that's not related to this ticket.
See Also: #9761