From 1c1b77aa7e055f4f7d755522c6a7ce08d0b3a461 Mon Sep 17 00:00:00 2001 From: Jacob Enget Date: Mon, 6 Jun 2016 13:45:14 -0500 Subject: [PATCH] Fixes typo causing problems with array element validation --- parson.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/parson.c b/parson.c index 7d62549..2983a33 100644 --- a/parson.c +++ b/parson.c @@ -1646,7 +1646,7 @@ JSON_Status json_validate(const JSON_Value *schema, const JSON_Value *value) { temp_schema_value = json_array_get_value(schema_array, 0); for (i = 0; i < json_array_get_count(value_array); i++) { temp_value = json_array_get_value(value_array, i); - if (json_validate(temp_schema_value, temp_value) == 0) { + if (json_validate(temp_schema_value, temp_value) == JSONFailure) { return JSONFailure; } }