| 7 | #include "cjson_utils.h" |
| 8 | |
| 9 | void cjson_set_parse_error(cJSONParseError *err, const char *format, ...) |
| 10 | { |
| 11 | if (!err) |
| 12 | return; |
| 13 | |
| 14 | err->code = CJSON_PARSE_FAILED; |
| 15 | va_list args; |
| 16 | va_start(args, format); |
| 17 | vsnprintf(err->message, sizeof(err->message), format, args); |
| 18 | va_end(args); |
| 19 | } |
| 20 | |
| 21 | void cjson_wrap_parse_error(cJSONParseError *err, const char *format, ...) |
| 22 | { |
no outgoing calls
no test coverage detected