-
- Downloads
netutils/cJSON: add input stream JSON parser
Patch provides new stream parsing engine. Benefits are: parsing input string using user supplied getc function, which allows reading input directly from files or socket streams (thus avoid temporary buffer allocation). Parser has also been fixed to pass all tests in 'json_gtest' folder. From github:thingsee/thingsee-sdk pull request: "Improve cJSON to allow parse/print from/to stream (caller supplied getc/putc functions) for reducing peak memory usage" https://github.com/thingsee/thingsee-sdk/pull/6 Signed-off-by:Jussi Kivilinna <jussi.kivilinna@haltian.com> (cherry picked from commit ed7c67771fcc97ffc9726241d6db70b24b0c0995)
Showing
- apps/include/netutils/cJSON.h 7 additions, 10 deletionsapps/include/netutils/cJSON.h
- apps/netutils/json/Makefile 1 addition, 1 deletionapps/netutils/json/Makefile
- apps/netutils/json/cJSON.c 10 additions, 46 deletionsapps/netutils/json/cJSON.c
- apps/netutils/json/cJSON_stream_parse.c 920 additions, 0 deletionsapps/netutils/json/cJSON_stream_parse.c
- apps/netutils/json_gtest/Makefile 3 additions, 1 deletionapps/netutils/json_gtest/Makefile
- apps/netutils/json_gtest/nuttx_glue.c 10 additions, 0 deletionsapps/netutils/json_gtest/nuttx_glue.c
Loading
Please register or sign in to comment