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 #6956

Null <int> returns 102

Details

Submitted2006-02-27 23:09 UTC
Fromrobbie at camrin dot org
StatusWont fix
PackageXML_RPC
PHP Version5.1.2
OSWin98
Roadmaps(Not assigned)

Comments

[2006-02-27 23:09 UTC] robbie at camrin dot org

Description:
------------
Getting a response as below... when decoded, the 'PlayerID' returns 102, when in fact it should be either 0 or null.

<member><name>PlayerID</name>
<value><int></int></value>
</member>
<member><name>PlayerName</name>
<value><string></string></value>
</member>

[2006-02-27 23:19 UTC] robbie at camrin dot org

Further investigation reveals that the message is actually coming from:
define('XML_RPC_ERROR_NON_NUMERIC_FOUND', 102);

because the line:
if (!ereg("^[+-]?[0123456789 \t\.]+$",$XML_RPC_xh[$parser]['ac']))

will treat an empty string as non-numeric.
Not sure it this is an error or not...