mirror of
https://github.com/DaveGamble/cJSON.git
synced 2024-12-27 14:14:07 +08:00
Fix -Wcomma
This commit is contained in:
parent
6c9f76c100
commit
186cce3ece
12
cJSON.c
12
cJSON.c
@ -2560,16 +2560,18 @@ CJSON_PUBLIC(cJSON_bool) cJSON_Compare(const cJSON * const a, const cJSON * cons
|
|||||||
|
|
||||||
case cJSON_Array:
|
case cJSON_Array:
|
||||||
{
|
{
|
||||||
cJSON *a_element = NULL;
|
cJSON *a_element = a->child;
|
||||||
cJSON *b_element = NULL;
|
cJSON *b_element = b->child;
|
||||||
for (a_element = a->child, b_element = b->child;
|
|
||||||
(a_element != NULL) && (b_element != NULL);
|
for (; (a_element != NULL) && (b_element != NULL);)
|
||||||
a_element = a_element->next, b_element = b_element->next)
|
|
||||||
{
|
{
|
||||||
if (!cJSON_Compare(a_element, b_element, case_sensitive))
|
if (!cJSON_Compare(a_element, b_element, case_sensitive))
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
a_element = a_element->next;
|
||||||
|
b_element = b_element->next;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user