mirror of
https://github.com/DaveGamble/cJSON.git
synced 2023-08-10 21:13:26 +03:00
cJSONUtils_ApplyPatches: Fix not accepting arrays
This was completely broken, arrays weren't accepted.
This commit is contained in:
parent
8c900b9e07
commit
62ba68fc7d
@ -526,12 +526,7 @@ CJSON_PUBLIC(int) cJSONUtils_ApplyPatches(cJSON *object, cJSON *patches)
|
||||
{
|
||||
int err = 0;
|
||||
|
||||
if (patches == NULL)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (cJSON_IsArray(patches))
|
||||
if (!cJSON_IsArray(patches))
|
||||
{
|
||||
/* malformed patches. */
|
||||
return 1;
|
||||
|
Loading…
Reference in New Issue
Block a user