From 6457c46897d6e0c63476bf4ba4ca14b4844fac0d Mon Sep 17 00:00:00 2001 From: m0gg Date: Thu, 23 Nov 2006 15:27:32 +0000 Subject: Code cleanup --- examples/csoap/soapclient.c | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) (limited to 'examples/csoap/soapclient.c') diff --git a/examples/csoap/soapclient.c b/examples/csoap/soapclient.c index c7d55f3..ea7d05f 100644 --- a/examples/csoap/soapclient.c +++ b/examples/csoap/soapclient.c @@ -7,19 +7,15 @@ #include #include #include -#include #include #include #include -#include -#include -#include -#include -#include -#include +// #include +// #include +// #include #include #include @@ -128,7 +124,7 @@ stripcslashes(char *str, int *len) // to the SOAP request */ void -ParseLine(SoapCtx * ctx, char *Buffer, int LineLen) +ParseLine(struct SoapCtx * ctx, char *Buffer, int LineLen) { char *Line, *FirstCommaPos, *SecondCommaPos; int len; @@ -191,7 +187,7 @@ printusage(char *FileName) int main(int argc, char *argv[]) { - SoapCtx *ctx, *ctx2; + struct SoapCtx *ctx, *ctx2; herror_t err; /* create buffer */ @@ -211,7 +207,7 @@ main(int argc, char *argv[]) err = soap_client_init_args(argc, argv); if (err != H_OK) { - log_error4("%s():%s [%d]", herror_func(err), + printf("%s():%s [%d]", herror_func(err), herror_message(err), herror_code(err)); herror_release(err); return 1; @@ -221,7 +217,7 @@ main(int argc, char *argv[]) err = soap_ctx_new_with_method(argv[2], argv[3], &ctx); if (err != H_OK) { - log_error4("%s():%s [%d]", herror_func(err), + printf("%s():%s [%d]", herror_func(err), herror_message(err), herror_code(err)); herror_release(err); return 1; @@ -244,7 +240,7 @@ main(int argc, char *argv[]) bytes_left = strlen(Buffer); if (bytes_left == MAX_LINE_LENGTH) { - log_error1("The parameter line is too long."); + printf("The parameter line is too long."); herror_release(err); soap_ctx_free(ctx); return 1; @@ -255,7 +251,7 @@ main(int argc, char *argv[]) err = soap_client_invoke(ctx, &ctx2, argv[1], ""); if (err != H_OK) { - log_error4("[%d] %s(): %s ", herror_code(err), + printf("[%d] %s(): %s ", herror_code(err), herror_func(err), herror_message(err)); herror_release(err); soap_ctx_free(ctx); @@ -263,7 +259,7 @@ main(int argc, char *argv[]) } /* print the result */ - soap_xml_doc_print(ctx2->env->root->doc); + xmlDocDump(stdout, ctx2->env->root->doc); /* free the objects */ soap_ctx_free(ctx2); -- cgit v1.1-32-gdbae