checking in json int fix
authorerickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 5 Oct 2005 14:10:31 +0000 (14:10 +0000)
committererickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 5 Oct 2005 14:10:31 +0000 (14:10 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@1896 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/src/apachemods/json_xml.c

index 669bddd..302f1ee 100644 (file)
@@ -115,12 +115,12 @@ void _rest_xml_output(growing_buffer* buf, jsonObject* obj, char * obj_class, in
                double x = jsonObjectGetNumber(obj);
                if (notag) {
                        if (x == (int)x)
-                               buffer_fadd(buf,"%d",tag, x,tag);
+                               buffer_fadd(buf,"%d",tag, (int)x,tag);
                        else
                                buffer_fadd(buf,"%lf",tag, x,tag);
                } else {
                        if (x == (int)x)
-                               buffer_fadd(buf,"<%s>%d</%s>",tag, x,tag);
+                               buffer_fadd(buf,"<%s>%d</%s>",tag, (int)x,tag);
                        else
                                buffer_fadd(buf,"<%s>%lf</%s>",tag, x,tag);
                }