| 436 | } |
| 437 | |
| 438 | static const char *json_array(ACL_JSON *json, const char *data) |
| 439 | { |
| 440 | ACL_JSON_NODE *array; |
| 441 | |
| 442 | SKIP_SPACE(data); |
| 443 | if (*data == 0) |
| 444 | return data; |
| 445 | |
| 446 | /* ����������� */ |
| 447 | array = acl_json_node_alloc(json); |
| 448 | array->left_ch = '['; |
| 449 | array->right_ch = ']'; |
| 450 | array->type = ACL_JSON_T_ARRAY; |
| 451 | array->depth = json->curr_node->depth + 1; |
| 452 | if (array->depth > json->depth) |
| 453 | json->depth = array->depth; |
| 454 | |
| 455 | acl_json_node_add_child(json->curr_node, array); |
| 456 | |
| 457 | if (LEN(json->curr_node->ltag) > 0) |
| 458 | json->curr_node->tag_node = array; |
| 459 | |
| 460 | json->curr_node = array; |
| 461 | json->status = ACL_JSON_S_ELEMENT; |
| 462 | |
| 463 | /* ���������Ϊ�գ���ֱ�Ӳ�ѯ���ֵܽڵ� */ |
| 464 | if (*data == ']') { |
| 465 | json->status = ACL_JSON_S_NEXT; |
| 466 | data++; |
| 467 | } |
| 468 | |
| 469 | return data; |
| 470 | } |
| 471 | |
| 472 | static const char *json_element(ACL_JSON *json, const char *data) |
| 473 | { |
nothing calls this directly
no test coverage detected
searching dependent graphs…