1
0
mirror of https://github.com/DaveGamble/cJSON synced 2024-12-22 06:40:04 +00:00

Free mem in cjson_set_valuestring_should_return_null_if_strings_overlap

This commit is contained in:
Nicolas Badoux 2024-08-26 09:48:59 +02:00 committed by Alan Wang
parent 4f4d7f70c2
commit 078c4e6c53

View File

@ -486,6 +486,7 @@ static void cjson_set_valuestring_should_return_null_if_strings_overlap(void)
/* If it overlaps, the string will be messed up.*/
TEST_ASSERT_TRUE(strcmp(str, "bcde") == 0);
TEST_ASSERT_NULL(str2);
cJSON_Delete(obj);
}
static void *CJSON_CDECL failing_realloc(void *pointer, size_t size)