PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » Web Services » XML_RPC » Bug #7116

Truncation of new lines where there shouldn't be

Details

Submitted2006-03-14 09:37 UTC
Fromcontax at phrenetic dot org
StatusDuplicate
PackageXML_RPC
PHP Version4.3.9
OSLinux ABOX 2.6.14-1.1653_FC4sm
Roadmaps(Not assigned)

Comments

[2006-03-14 09:37 UTC] contax at phrenetic dot org

Description:
------------
Line 1207 of XML/RPC.php does nasty things:

$this->payload = ereg_replace("[\r\n]+", "\r\n", $this->payload);

It ensures that there is never more that one line break concurrently throughout the entire XML request. So if you're sending the following string:

"This

is

some

text"

It will be converted to:

"This
is
some
text"

I'm not too sure why this line is require in the first place. Commenting out the line doesn't seem to have an adverse effect.