return enc;
}
-static void schema_load_file(sdlCtx *ctx, xmlAttrPtr ns, xmlChar *location, xmlAttrPtr tns, int import) {
+static void schema_load_file(sdlCtx *ctx, xmlAttrPtr ns, xmlChar *location, xmlAttrPtr tns, int import TSRMLS_DC) {
if (location != NULL &&
!zend_hash_exists(&ctx->docs, location, strlen(location)+1)) {
xmlDocPtr doc;
xmlNodePtr schema;
xmlAttrPtr new_tns;
- doc = soap_xmlParseFile(location);
+ doc = soap_xmlParseFile(location TSRMLS_CC);
if (doc == NULL) {
soap_error1(E_ERROR, "Parsing Schema: can't import schema from '%s'", location);
}
}
}
zend_hash_add(&ctx->docs, location, strlen(location)+1, (void**)&doc, sizeof(xmlDocPtr), NULL);
- load_schema(ctx, schema);
+ load_schema(ctx, schema TSRMLS_CC);
}
}
Content: ((include | import | redefine | annotation)*, (((simpleType | complexType | group | attributeGroup) | element | attribute | notation), annotation*)*)
</schema>
*/
-int load_schema(sdlCtx *ctx,xmlNodePtr schema)
+int load_schema(sdlCtx *ctx, xmlNodePtr schema TSRMLS_DC)
{
xmlNodePtr trav;
xmlAttrPtr tns;
uri = xmlBuildURI(location->children->content, base);
xmlFree(base);
}
- schema_load_file(ctx,NULL,uri,tns,0);
+ schema_load_file(ctx, NULL, uri, tns, 0 TSRMLS_CC);
xmlFree(uri);
}
uri = xmlBuildURI(location->children->content, base);
xmlFree(base);
}
- schema_load_file(ctx,NULL,uri,tns,0);
+ schema_load_file(ctx, NULL, uri, tns, 0 TSRMLS_CC);
xmlFree(uri);
/* TODO: <redefine> support */
}
xmlFree(base);
}
}
- schema_load_file(ctx,ns,uri,tns,1);
+ schema_load_file(ctx, ns, uri, tns, 1 TSRMLS_CC);
if (uri != NULL) {xmlFree(uri);}
} else if (node_is_equal(trav,"annotation")) {
/* TODO: <annotation> support */
return;
}
- wsdl = soap_xmlParseFile(struri);
+ wsdl = soap_xmlParseFile(struri TSRMLS_CC);
if (!wsdl) {
soap_error1(E_ERROR, "Parsing WSDL: Couldn't load from '%s'", struri);
if (include) {
xmlNodePtr schema = get_node_ex(root, "schema", XSD_NAMESPACE);
if (schema) {
- load_schema(ctx, schema);
+ load_schema(ctx, schema TSRMLS_CC);
return;
}
}
while (trav2 != NULL) {
if (node_is_equal_ex(trav2, "schema", XSD_NAMESPACE)) {
- load_schema(ctx, trav2);
+ load_schema(ctx, trav2 TSRMLS_CC);
} else if (is_wsdl_element(trav2) && !node_is_equal(trav2,"documentation")) {
soap_error1(E_ERROR, "Parsing WSDL: Unexpected WSDL element <%s>", trav2->name);
}
#define node_is_equal(node, name) node_is_equal_ex(node, name, NULL)
#define attr_is_equal(node, name) attr_is_equal_ex(node, name, NULL)
-xmlDocPtr soap_xmlParseFile(const char *filename);
+xmlDocPtr soap_xmlParseFile(const char *filename TSRMLS_DC);
xmlDocPtr soap_xmlParseMemory(const void *buf, size_t size);
xmlNsPtr attr_find_ns(xmlAttrPtr node);