| 2124 | } |
| 2125 | |
| 2126 | CJSON_PUBLIC(cJSON*) cJSON_AddBoolToObject(cJSON * const object, const char * const name, const cJSON_bool boolean) |
| 2127 | { |
| 2128 | cJSON *bool_item = cJSON_CreateBool(boolean); |
| 2129 | if (add_item_to_object(object, name, bool_item, &global_hooks, false)) |
| 2130 | { |
| 2131 | return bool_item; |
| 2132 | } |
| 2133 | |
| 2134 | cJSON_Delete(bool_item); |
| 2135 | return NULL; |
| 2136 | } |
| 2137 | |
| 2138 | CJSON_PUBLIC(cJSON*) cJSON_AddNumberToObject(cJSON * const object, const char * const name, const double number) |
| 2139 | { |
nothing calls this directly
no test coverage detected
searching dependent graphs…