dmitry Tue Nov 13 15:10:28 2007 UTC
Modified files:
/php-src/ext/soap soap.c
/php-src/ext/soap/tests/bugs bug42692.phpt bug42692.wsdl
Log:
Fixed bug #42692 (Procedure 'int1' not present with doc/lit SoapServer)
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/soap.c?r1=1.236&r2=1.237&diff_format=u
Index: php-src/ext/soap/soap.c
diff -u php-src/ext/soap/soap.c:1.236 php-src/ext/soap/soap.c:1.237
--- php-src/ext/soap/soap.c:1.236 Thu Nov 1 15:43:17 2007
+++ php-src/ext/soap/soap.c Tue Nov 13 15:10:28 2007
@@ -17,7 +17,7 @@
| Dmitry Stogov <[EMAIL PROTECTED]> |
+----------------------------------------------------------------------+
*/
-/* $Id: soap.c,v 1.236 2007/11/01 15:43:17 dmitry Exp $ */
+/* $Id: soap.c,v 1.237 2007/11/13 15:10:28 dmitry Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -5000,6 +5000,7 @@
break;
}
zend_hash_move_forward((*tmp)->requestParameters);
+ node = node->next;
}
if (ok /*&& node == NULL*/) {
return (*tmp);
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/tests/bugs/bug42692.phpt?r1=1.1&r2=1.2&diff_format=u
Index: php-src/ext/soap/tests/bugs/bug42692.phpt
diff -u /dev/null php-src/ext/soap/tests/bugs/bug42692.phpt:1.2
--- /dev/null Tue Nov 13 15:10:28 2007
+++ php-src/ext/soap/tests/bugs/bug42692.phpt Tue Nov 13 15:10:28 2007
@@ -0,0 +1,37 @@
+--TEST--
+Bug #42692 (Procedure 'int1' not present with doc/lit SoapServer)
+--FILE--
+<?php
+ini_set('soap.wsdl_cache_enabled','0');
+
+function checkAuth($peid,$auth) {
+ return $peid;
+}
+
+class TestSoap extends SoapClient {
+
+ function __construct($wsdl, $options) {
+ parent::__construct($wsdl, $options);
+ $this->server = new SoapServer($wsdl, $options);
+ $this->server->addFunction("checkAuth");
+ }
+
+ function __doRequest($request, $location, $action, $version) {
+ ob_start();
+ $this->server->handle($request);
+ $response = ob_get_contents();
+ ob_end_clean();
+ return $response;
+ }
+}
+
+$client = new TestSoap(dirname(__FILE__) . "/bug42692.wsdl",
array("trace"=>1));
+try {
+ $result = $client->checkAuth(1,"two");
+ echo "Auth for 1 is $result\n";
+} catch (Exception $e) {
+ echo $e->getMessage();
+}
+?>
+--EXPECT--
+Auth for 1 is 1
http://cvs.php.net/viewvc.cgi/php-src/ext/soap/tests/bugs/bug42692.wsdl?r1=1.1&r2=1.2&diff_format=u
Index: php-src/ext/soap/tests/bugs/bug42692.wsdl
diff -u /dev/null php-src/ext/soap/tests/bugs/bug42692.wsdl:1.2
--- /dev/null Tue Nov 13 15:10:28 2007
+++ php-src/ext/soap/tests/bugs/bug42692.wsdl Tue Nov 13 15:10:28 2007
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<definitions name="netDB"
+ targetNamespace="urn:netDB"
+ xmlns:typens="urn:netDB"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
+ xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+ xmlns="http://schemas.xmlsoap.org/wsdl/">
+ <message name="checkAuthIN">
+ <part name="peid" type="xsd:integer" />
+ <part name="auth" type="xsd:string" />
+ </message>
+ <message name="checkAuthOUT">
+ <part name="peidx" type="xsd:integer" />
+ </message>
+ <portType name="netDB">
+ <operation name="checkAuth">
+ <input message="typens:checkAuthIN" />
+ <output message="typens:checkAuthOUT" />
+ </operation>
+ </portType>
+ <binding name="netDB" type="typens:netDB">
+ <soap:binding type="rpc"
transport="http://schemas.xmlsoap.org/soap/http" />
+ <operation name="checkAuth">
+ <soap:operation soapAction="urn:checkAuth" />
+ <input>
+ <soap:body use="encoded" namespace="urn:netDB"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
+ </input>
+ <output>
+ <soap:body use="encoded" namespace="urn:netDB"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
+ </output>
+ </operation>
+ </binding>
+ <service name="netDB">
+ <port name="netDBPort" binding="typens:netDB">
+ <soap:address
location="http://netdb.alphawest.com.au/xml/soap/server.php"/>
+ </port>
+ </service>
+</definitions>
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php