Branch Coverage

third_party/modest/source/mycore/utils/mcobject_async.c
Criterion Covered Total %
branch 53 134 39.5


line true false branch
32 435 0 if(mcobj_async->chunks[ mcobj_async->chunks_pos_length ] == NULL) {
35 0 435 if(mcobj_async->chunks[ mcobj_async->chunks_pos_length ] == NULL)
53 0 435 if(mcobj_async->chunks == NULL)
61 0 435 if(mcobj_async->chunk_cache == NULL)
68 0 435 if(mcobj_async->nodes == NULL)
75 0 435 if(mcobj_async->nodes_cache == NULL)
81 0 435 if(mcobj_async->mcsync == NULL)
84 0 435 if(mcsync_init(mcobj_async->mcsync))
92 435 0 if(mcobj_async->chunks[0] != NULL)
101 0 435 for (node_idx = 0; node_idx < mcobj_async->nodes_length; node_idx++)
106 0 0 if(node->chunk) {
114 0 432 if(mcobj_async == NULL)
117 432 0 if(mcobj_async->nodes)
119 720 432 for (size_t node_idx = 0; node_idx < mcobj_async->nodes_length; node_idx++)
123 720 0 if(node->cache)
130 432 0 if(mcobj_async->nodes_cache) {
134 432 0 if(mcobj_async->chunks) {
135 432 432 for (size_t pos_idx = 0; pos_idx < mcobj_async->chunks_pos_length; pos_idx++) {
136 432 0 if(mcobj_async->chunks[pos_idx])
138 55296 432 for (size_t idx = 0; idx < mcobj_async->chunks_size; idx++) {
139 720 54576 if(mcobj_async->chunks[pos_idx][idx].begin)
150 432 0 if(mcobj_async->chunk_cache) {
158 432 0 if(destroy_self)
168 0 725 if(chunk->begin) {
169 0 0 if(length > chunk->size) {
179 0 725 if(length > chunk->size)
187 0 725 if(chunk->begin == NULL)
195 435 290 if(status)
198 0 725 if(mcobj_async->chunk_cache_length)
209 0 725 if(mcobj_async->chunks_length >= mcobj_async->chunks_size)
211 0 0 if(mcobj_async->chunks_pos_length >= mcobj_async->chunks_pos_size)
217 0 0 if(tmp_pos)
226 0 0 if(status)
233 0 0 if(mcobject_async_chunk_up(mcobj_async)) {
234 0 0 if(status)
249 435 290 if(status)
259 0 0 if(mcsync_lock(mcobj_async->mcsync)) {
260 0 0 if(status)
276 435 290 if(status)
281 0 725 if(mcobj_async->nodes_cache_length) {
287 0 725 if(mcobj_async->nodes_length >= mcobj_async->nodes_size) {
300 435 290 if(status && *status) {
0 435 if(status && *status) {
312 0 725 if(node->cache == NULL) {
313 0 0 if(status)
327 0 725 if(mcobj_async->nodes_length <= node_idx)
333 0 725 if(node->chunk == NULL)
336 0 725 while (node->chunk->prev)
345 0 0 for (size_t node_idx = 0; node_idx < mcobj_async->nodes_length; node_idx++) {
354 0 0 if(mcobj_async->nodes_length <= node_idx) {
362 0 0 while (chunk->next)
365 0 0 while (chunk)
367 0 0 if(mcobj_async->chunk_cache_length >= mcobj_async->chunk_cache_size) {
373 0 0 if(tmp) {
390 0 0 if(node->cache)
395 0 0 if(mcobj_async->nodes_cache_length >= mcobj_async->nodes_cache_size) {
400 0 0 if(tmp) {
416 105 4422 if(node->cache_length) {
417 0 105 if(status)
424 0 4422 if(node->chunk->length >= node->chunk->size)
426 0 0 if(node->chunk->next) {
434 0 0 if(mystatus) {
435 0 0 if(status)
448 0 4422 if(status)
462 0 342 if(node_idx >= mcobj_async->nodes_length)
467 0 342 if(node->cache_length >= node->cache_size) {
472 0 0 if(tmp) {