examples/wgetjson: fix concatenation len buffer json
This commit is contained in:
parent
5c1626c764
commit
b11dcc34c6
@ -148,7 +148,7 @@ static int wgetjson_callback(FAR char **buffer, int offset, int datend,
|
|||||||
if (new_json_buff)
|
if (new_json_buff)
|
||||||
{
|
{
|
||||||
g_json_buff = new_json_buff;
|
g_json_buff = new_json_buff;
|
||||||
memcpy(&g_json_buff[g_json_bufflen - 1], &((*buffer)[offset]),
|
memcpy(&g_json_buff[g_json_bufflen], &((*buffer)[offset]),
|
||||||
len);
|
len);
|
||||||
g_json_buff[g_json_bufflen + len] = 0;
|
g_json_buff[g_json_bufflen + len] = 0;
|
||||||
g_json_bufflen += org;
|
g_json_bufflen += org;
|
||||||
|
Loading…
Reference in New Issue
Block a user