Menu

#155 XMLRPC faultCode should be integer

0.71
open
Protocol (8)
5
2014-08-15
2008-09-24
No

stumbled across this in the course of using bugzilla's testopia, which utilizes SOAP::Lite for xmlrpc webservices. I'll admit to no small amount of confusion on the relationship to/support of xmlrpc in SOAP::Lite, so apologies in advance if this bug is out of line.

what I find is that xmlrpc expects the faultCode in an error response to be numeric, but in Lite.pm it may send back the string "Server". this causes apache's java xmlrpc client to blow its stack on a cast error, as it really wants faultCode to be a string.

the code in question is in Lite.pm (looking at v1.77 on CVS, though I've got 1.41 on my box), line 2768:
2763 # let application errors pass through with 'Server' code
2764 die ref $@
2765 ? $@
2766 : $@ =~ /^Can\'t locate object method "$method_name"/
2767 ? "Failed to locate method ($method_name) in class ($class)"
2768 : SOAP::Fault->faultcode($SOAP::Constants::FAULT_SERVER)->faultstring($@)
2769 if $@;

in Constants.pm we see the definition:
$FAULT_SERVER = 'Server';

Discussion

  • Nobody/Anonymous

    Bugzilla bug has a workaround patch attached.

     

Log in to post a comment.

MongoDB Logo MongoDB