Re: [PATCH] xmlrpc missing features implementation

"Robert Galach" <[email protected]>
Newsgroups gmane.comp.mobile.kannel.devel
Message-ID <[email protected]>
Hi,
Could you guys look at the patch and vote?
Stipe? Alex? What do you think about it?

I've just received a patch that corrects parsing fault response,
thank you Fred:

> +++ gwlib/xmlrpc.c      2004-03-18 17:04:43.000000000 -0500
> @@ -2567,9 +2567,9 @@
>           */
>          if (xmlrpc_value_get_type(value) != xr_struct ||
>              (v_code = xmlrpc_get_member(value, octstr_imm("faultCode")))
== NULL ||
> -            xmlrpc_value_get_type(v_code) != xr_int ||
> +            xmlrpc_value_get_type_smart(v_code) != xr_int ||
>              (v_string = xmlrpc_get_member(value,
octstr_imm("faultString"))) == NULL ||
> -            xmlrpc_value_get_type(v_string) != xr_string ||
> +            xmlrpc_value_get_type_smart(v_string) != xr_string ||
>              xmlrpc_count_members(value) != 2) {
>
>              xrdoc->parse_status = XMLRPC_PARSING_FAILED;
> @@ -2578,8 +2578,8 @@
>              xmlrpc_value_destroy(value);
>              return -1;
>          }
> -        fault->f_code = *(long *)xmlrpc_value_get_content(v_code);
> -        fault->f_string = octstr_duplicate((Octstr
*)xmlrpc_value_get_content(v_string));
> +        fault->f_code = xmlrpc_scalar_get_int((XMLRPCScalar *)
xmlrpc_value_get_content(v_code));
> +        fault->f_string = xmlrpc_scalar_get_string((XMLRPCScalar *)
xmlrpc_value_get_content(v_string));
>
>          xmlrpc_value_destroy(value);
>      } else {
>
> Fred Wittekind
> eGIX SysAdmin


Attached full patch again, but with above changes.

Regards
Robert
xmlrpc_implement_missing.patch.gz (application/octet-stream, 19.3 KB) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.