duffleit / xmlrpcnet

Automatically exported from code.google.com/p/xmlrpcnet
0 stars 0 forks source link

NullReferenceException when struct member name empty string #25

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
From Maxim Mironenko:

I found place in you code with "System.NullReferenceException was
 unhandled"
 at CookComputing.XmlRpc.XmlRpcSerializer.ParseHashtable(XmlNode node, Type
valueType, ParseStack parseStack, MappingAction mappingAction)
 in XmlRpcSerializer.cs:line 1317

   string rpcName = nameNode.FirstChild.Value;

 This happens when struct member looks like this:
<member>
 <name></name>
 <value>
   <string>Blah-blah</string>
 </value>
</member>

 For repeating this problem try to create an array with "" (empty
 string) key for value in PHP, like this:

 $fail_array = array (
     'tablename' => 'node',
     'field' => 'status',
     '' => 'Blah-blah',
     'value' => '1');

 And when you try to transfer this array via XML-RPC you will get
 this error.

Original issue reported on code.google.com by edwardfo...@gmail.com on 30 May 2008 at 4:03

GoogleCodeExporter commented 9 years ago
Fixed in revision 58.

Original comment by ChasC...@gmail.com on 30 Aug 2008 at 2:05

GoogleCodeExporter commented 9 years ago

Original comment by ChasC...@gmail.com on 7 Dec 2008 at 10:01

GoogleCodeExporter commented 9 years ago

Original comment by ChasC...@gmail.com on 7 Dec 2008 at 10:01