Skip to content

Commit 74143f3

Browse files
committed
fix leak in unit-tests
1 parent 56650e8 commit 74143f3

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/test_lib_json/main.cpp

+2
Original file line numberDiff line numberDiff line change
@@ -2209,6 +2209,7 @@ JSONTEST_FIXTURE(CharReaderAllowSingleQuotesTest, issue182) {
22092209
JSONTEST_ASSERT_STRING_EQUAL("x", root["a"].asString());
22102210
JSONTEST_ASSERT_STRING_EQUAL("y", root["b"].asString());
22112211
}
2212+
delete reader;
22122213
}
22132214

22142215
struct CharReaderAllowZeroesTest : JsonTest::TestCase {};
@@ -2241,6 +2242,7 @@ JSONTEST_FIXTURE(CharReaderAllowZeroesTest, issue176) {
22412242
JSONTEST_ASSERT_STRING_EQUAL("x", root["a"].asString());
22422243
JSONTEST_ASSERT_STRING_EQUAL("y", root["b"].asString());
22432244
}
2245+
delete reader;
22442246
}
22452247

22462248
struct BuilderTest : JsonTest::TestCase {};

0 commit comments

Comments
 (0)