Commit 08ad159f authored by Volodymyr Yurchenko's avatar Volodymyr Yurchenko Committed by Nikola Hardi
Browse files

In StdOut print only the 'message' part of server reply

parent 71cb271c
......@@ -528,23 +528,14 @@ void TJAlien::Stdout()
json_object_object_get_ex(jobj_res, "results", &js_results);
if (js_results != NULL && json_object_is_type(js_results, json_type_array))
{
/*TString message_stream = json_object_get_string(json_object_object_get(js_results, "message"));
if (message_stream != NULL && message_stream.Length() != 0)
printf("%s\n", message_stream.Data());*/
int arraylen = json_object_array_length(js_results);
int i;
for (i = 0; i < arraylen; i++)
{
//Info("TJAlien", "===================");
json_object *jvalue = json_object_array_get_idx(js_results, i);
json_object_object_foreach(jvalue, key, val)
{
printf("%s\t", json_object_get_string(val));
UNUSED(key);
}
printf("\n");
TString message_stream = json_object_get_string(json_object_object_get(jvalue, "message"));
if (message_stream != NULL && message_stream.Length() != 0)
printf("%s\n", message_stream.Data());
}
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment