MCPcopy Create free account
hub / github.com/acl-dev/acl / acl_cjson_test

Function acl_cjson_test

lib_acl_cpp/samples/benchmark/json/main.cpp:146–161  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

144}
145
146static int acl_cjson_test(const acl::string& data, int count) {
147 int i;
148
149 for (i = 0; i < count; i++) {
150 ACL_JSON* json = acl_json_alloc();
151 acl_json_update(json, data.c_str());
152 if (!acl_json_finish(json)) {
153 printf("acl cjson: invalid json\r\n");
154 break;
155 }
156 acl_json_free(json);
157 //acl_json_reset(json);
158 }
159
160 return i;
161}
162
163static void usage(const char* procname) {
164 printf("usage: %s -h [help] -f filename, -n max_loop\r\n", procname);

Callers 1

mainFunction · 0.85

Calls 5

acl_json_allocFunction · 0.85
acl_json_updateFunction · 0.85
acl_json_finishFunction · 0.85
acl_json_freeFunction · 0.85
c_strMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…