aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/samples/HelloWorld.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/samples/HelloWorld.c')
-rw-r--r--plugins/samples/HelloWorld.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/samples/HelloWorld.c b/plugins/samples/HelloWorld.c
index 05bec957..067365dd 100644
--- a/plugins/samples/HelloWorld.c
+++ b/plugins/samples/HelloWorld.c
@@ -30,7 +30,7 @@ STATIC json_object* pingSample (AFB_request *request) {
if (len == 0) strcpy (query,"NoSearchQueryList");
// check if we have some post data
- if (request->post == NULL) request->post->data="NoData";
+ if (request->post != NULL) request->post->data="NoData";
// return response to caller
response = jsonNewMessage(AFB_SUCCESS, "Ping Binder Daemon %d query={%s} PostData: \'%s\' ", pingcount++, query, request->post);