diff options
author | Dmitry Stogov <dmitry@php.net> | 2004-01-19 07:22:53 +0000 |
---|---|---|
committer | Dmitry Stogov <dmitry@php.net> | 2004-01-19 07:22:53 +0000 |
commit | a68777e9545a505635f60bd881c5771e36cd4e69 (patch) | |
tree | 3f23f09962be50125a52d1973f14507ae0f373fb /ext/soap/php_sdl.c | |
parent | 608db4728b56eaab9bcbc931d3762dfd2fbcee71 (diff) | |
download | php-git-a68777e9545a505635f60bd881c5771e36cd4e69.tar.gz |
XML Scheam support
Diffstat (limited to 'ext/soap/php_sdl.c')
-rw-r--r-- | ext/soap/php_sdl.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/ext/soap/php_sdl.c b/ext/soap/php_sdl.c index b898035898..c694f8bdd7 100644 --- a/ext/soap/php_sdl.c +++ b/ext/soap/php_sdl.c @@ -33,7 +33,7 @@ encodePtr get_encoder_from_element(sdlPtr sdl, xmlNodePtr node, const char *type encodePtr enc = NULL; TSRMLS_FETCH(); - if (sdl && sdl->types) { + if (sdl && sdl->elements) { xmlNsPtr nsptr; char *ns, *cptype; sdlTypePtr *sdl_type; @@ -48,14 +48,14 @@ encodePtr get_encoder_from_element(sdlPtr sdl, xmlNodePtr node, const char *type smart_str_appends(&nscat, cptype); smart_str_0(&nscat); - if (zend_hash_find(sdl->types, nscat.c, nscat.len + 1, (void **)&sdl_type) == SUCCESS) { + if (zend_hash_find(sdl->elements, nscat.c, nscat.len + 1, (void **)&sdl_type) == SUCCESS) { enc = (*sdl_type)->encode; - } else if (zend_hash_find(sdl->types, (char*)type, strlen(type) + 1, (void **)&sdl_type) == SUCCESS) { + } else if (zend_hash_find(sdl->elements, (char*)type, strlen(type) + 1, (void **)&sdl_type) == SUCCESS) { enc = (*sdl_type)->encode; } smart_str_free(&nscat); } else { - if (zend_hash_find(sdl->types, (char*)type, strlen(type) + 1, (void **)&sdl_type) == SUCCESS) { + if (zend_hash_find(sdl->elements, (char*)type, strlen(type) + 1, (void **)&sdl_type) == SUCCESS) { enc = (*sdl_type)->encode; } } @@ -895,6 +895,10 @@ void delete_sdl(void *handle) zend_hash_destroy(tmp->types); free(tmp->types); } + if (tmp->elements) { + zend_hash_destroy(tmp->elements); + free(tmp->elements); + } if (tmp->bindings) { zend_hash_destroy(tmp->bindings); free(tmp->bindings); |