Tweak tests for greater allocation failure coverage
This commit is contained in:
parent
7653beecee
commit
9a7d8d2c3f
@ -3862,9 +3862,17 @@ START_TEST(test_alloc_ext_entity_set_encoding)
|
||||
"]>\n"
|
||||
"<doc>&en;</doc>";
|
||||
int i;
|
||||
int repeat = 0;
|
||||
#define MAX_ALLOCATION_COUNT 20
|
||||
|
||||
for (i = 0; i < MAX_ALLOCATION_COUNT; i++) {
|
||||
/* Repeat some counts to get round caching */
|
||||
if ((i == 2 && repeat < 3) ||
|
||||
(i == 3 && repeat < 6) ||
|
||||
(i == 4 && repeat == 6)) {
|
||||
i--;
|
||||
repeat++;
|
||||
}
|
||||
XML_SetExternalEntityRefHandler(parser,
|
||||
external_entity_alloc_set_encoding);
|
||||
allocation_count = i;
|
||||
|
Loading…
Reference in New Issue
Block a user