From: giunta dot gaetano at sea-aeroportimilano dot it
Operating system: windows 2000
PHP version: 4.4.4
PHP Bug Type: XMLRPC-EPI related
Bug description: xmlrpc_encode_request generates invalid xmlrpc request
Description:
------------
If an array containing members 'faultCode' and 'faultString' is passed as
second parameter to xmlrpc_encode_request, a weird xml is generated,
containing a methocall member and a fault member. Needless to say, it is
not a valid xmlrpc request...
Reproduce code:
---------------
xmlrpc_encode_request('hello', array('faultCode' => 666, 'faultString' =>
'hello world'))
Expected result:
----------------
<?xml version="1.0" encoding="iso-8859-1"?>
<methodCall>
<methodName>hello</methodName>
<params>
<param>
<value><struct>
<member><name>faultCode</name>
<value><int>666</int></value>
</member>
<member><name>faultString</name>
<value><string>hello world</string></value>
</member>
</struct></value>
</param>
</params>
</methodCall>
Actual result:
--------------
<?xml version="1.0" encoding="iso-8859-1"?>
<methodCall>
<methodName>hello</methodName>
<fault>
<value>
<struct>
<member>
<name>faultCode</name>
<value>
<int>666</int>
</value>
</member>
<member>
<name>faultString</name>
<value>
<string>hello world</string>
</value>
</member>
</struct>
</value>
</fault>
</methodCall>
--
Edit bug report at http://bugs.php.net/?id=38494&edit=1
--
Try a CVS snapshot (PHP 4.4):
http://bugs.php.net/fix.php?id=38494&r=trysnapshot44
Try a CVS snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=38494&r=trysnapshot52
Try a CVS snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=38494&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=38494&r=fixedcvs
Fixed in release:
http://bugs.php.net/fix.php?id=38494&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=38494&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=38494&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=38494&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=38494&r=support
Expected behavior: http://bugs.php.net/fix.php?id=38494&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=38494&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=38494&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=38494&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=38494&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=38494&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=38494&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=38494&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=38494&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=38494&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=38494&r=mysqlcfg