Opened 2 months ago
Last modified 2 weeks ago
#23811 new defect (bug)
XML-RPC shouldn't display errors
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | 3.6 |
| Component: | XML-RPC | Version: | 3.5.1 |
| Severity: | normal | Keywords: | mobile has-patch |
| Cc: | koke |
Description
I've got some user reports of XML-RPC returning this:
<b>Warning</b> <a href='function.strpos'>function.strpos</a> <b> /home/www/simplythreemusic.com/wp-includes/class-wp-xmlrpc-server.php</b>
In this case, it seems to be #18310, but XML-RPC shouldn't be throwing any warnings, since that makes the client think the request failed when it actually succeeded
Attachments (2)
Change History (7)
markoheijnen — 2 months ago
comment:1
markoheijnen — 2 months ago
- Milestone changed from Awaiting Review to 3.6
Moving to 3.6 for future discussions.
comment:2
SergeyBiryukov — 2 months ago
Related: #23017
- Keywords has-patch added
23811.2.diff is similar to Marko's patch but for the WP_DEBUG_DISPLAY constant instead, which then sets display_errors.
comment:4
markoheijnen — 2 weeks ago
That doesn't exactly works the same. Your patch only works when WP_DEBUG is true and my one only works when WP_DEBUG is false.
I guess the issue here is that the server definition is display_errors: 1. So I guess both patches make sense to commit then?
comment:5
SergeyBiryukov — 2 weeks ago
23811.diff makes sense to me.
Not sure if WP_DEBUG_DISPLAY should default to false for XML-RPC. Should we do the same for AJAX in that case? I guess it should still default to true, otherwise it would make debugging harder.

Possible fix