Extend XML_GetBuffer testing coverage

This commit is contained in:
Rhodri James 2017-02-07 18:05:55 +00:00 committed by Sebastian Pipping
parent 1c3c9b2bd5
commit 28d9f9938f

View File

@ -2000,7 +2000,11 @@ START_TEST(test_get_buffer)
if (XML_GetBuffer(parser, INT_MAX) != NULL)
fail("INT_MAX buffer not failed");
/* Now try extending it a more reasonable amount */
/* Now try extending it a more reasonable but still too large amount */
if (XML_GetBuffer(parser, INT_MAX - 2049) != NULL)
fail("INT_MAX- buffer not failed");
/* Now try extending it a carefully crafted amount */
if (XML_GetBuffer(parser, 1000) == NULL)
fail("1000 buffer failed");
}