summaryrefslogtreecommitdiffstats
path: root/bindings/samples/HelloWorld.c
diff options
context:
space:
mode:
Diffstat (limited to 'bindings/samples/HelloWorld.c')
-rw-r--r--bindings/samples/HelloWorld.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/bindings/samples/HelloWorld.c b/bindings/samples/HelloWorld.c
index b6f49b78..15544895 100644
--- a/bindings/samples/HelloWorld.c
+++ b/bindings/samples/HelloWorld.c
@@ -144,16 +144,16 @@ static void pingEvent(struct afb_req request)
// For samples https://linuxprograms.wordpress.com/2010/05/20/json-c-libjson-tutorial/
static void pingJson (struct afb_req request) {
- json_object *jresp, *embed;
-
+ json_object *jresp, *embed;
+
jresp = json_object_new_object();
json_object_object_add(jresp, "myString", json_object_new_string ("Some String"));
json_object_object_add(jresp, "myInt", json_object_new_int (1234));
-
+
embed = json_object_new_object();
json_object_object_add(embed, "subObjString", json_object_new_string ("Some String"));
json_object_object_add(embed, "subObjInt", json_object_new_int (5678));
-
+
json_object_object_add(jresp,"eobj", embed);
ping(request, jresp, "pingJson");