summaryrefslogtreecommitdiff
path: root/ext/soap/soap.c
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@php.net>2004-01-10 09:27:52 +0000
committerDmitry Stogov <dmitry@php.net>2004-01-10 09:27:52 +0000
commit170476d9ea72e004341d2034715199f21ae68ba9 (patch)
tree94e3eb4686ecdf27075b9f324d21d2f15d135050 /ext/soap/soap.c
parent1101a375c3b59a5c6d02bb32455883575c809871 (diff)
downloadphp-git-170476d9ea72e004341d2034715199f21ae68ba9.tar.gz
BUGFIX: server006.phpt
Diffstat (limited to 'ext/soap/soap.c')
-rw-r--r--ext/soap/soap.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/ext/soap/soap.c b/ext/soap/soap.c
index 8755754208..624cf5c167 100644
--- a/ext/soap/soap.c
+++ b/ext/soap/soap.c
@@ -1088,10 +1088,17 @@ PHP_METHOD(soapserver, handle)
/* If new session or something wierd happned */
if (soap_obj == NULL) {
zval *tmp_soap;
+ char *class_name;
+ int class_name_len;
+
MAKE_STD_ZVAL(tmp_soap);
object_init_ex(tmp_soap, service->soap_class.ce);
+
/* Call constructor */
- if (zend_hash_exists(&Z_OBJCE_P(tmp_soap)->function_table, service->soap_class.ce->name, strlen(service->soap_class.ce->name) + 1)) {
+ class_name_len = strlen(service->soap_class.ce->name);
+ class_name = emalloc(class_name_len+1);
+ memcpy(class_name, service->soap_class.ce->name,class_name_len+1);
+ if (zend_hash_exists(&Z_OBJCE_P(tmp_soap)->function_table, php_strtolower(class_name, class_name_len), class_name_len+1)) {
zval c_ret, constructor;
INIT_ZVAL(c_ret);
@@ -1104,6 +1111,7 @@ PHP_METHOD(soapserver, handle)
zval_dtor(&constructor);
zval_dtor(&c_ret);
}
+ efree(class_name);
#if HAVE_PHP_SESSION
/* If session then update session hash with new object */
if (service->soap_class.persistance == SOAP_PERSISTENCE_SESSION) {