From 32129e70e7184b03ec52e84936b35f1c1283980b Mon Sep 17 00:00:00 2001 From: Petr Pisar Date: Sun, 25 Oct 2009 00:10:49 +0200 Subject: [PATCH] soap(): use xmlNewChild() instead of xmlNewNode() and xmlAddChild() --- src/soap.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/soap.c b/src/soap.c index f4a40a2..32c8efe 100644 --- a/src/soap.c +++ b/src/soap.c @@ -281,14 +281,9 @@ _hidden isds_error soap(struct isds_ctx *context, const char *file, goto leave; } xmlSetNs(request_soap_envelope, soap_ns); - /* TODO: Use xmlNewChild() instead of xmlNewNode() + xmlAddChild() */ - request_soap_body = xmlNewNode(soap_ns, BAD_CAST "Body"); + request_soap_body = xmlNewChild(request_soap_envelope, NULL, + BAD_CAST "Body", NULL); if (!request_soap_body) { - isds_log_message(context, _("Could not create SOAP request body")); - err = IE_ERROR; - goto leave; - } - if (!xmlAddChild(request_soap_envelope, request_soap_body)) { isds_log_message(context, _("Could not add Body to SOAP request envelope")); err = IE_ERROR; goto leave; -- 2.11.4.GIT