Commit e16fc94b authored by Rusty Russell's avatar Rusty Russell

configurator: fix crash when more than one extra test provided

Signed-off-by: default avatarRusty Russell <rusty@rustcorp.com.au>
parent 9d2d2c49
......@@ -888,7 +888,8 @@ static void read_tests(size_t num_tests)
{
while (read_test(tests + num_tests)) {
num_tests++;
tests = realloc(tests, num_tests * sizeof(tests[0]));
tests = realloc(tests, (num_tests + 1) * sizeof(tests[0]));
tests[num_tests].name = NULL;
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment