Fix a bug in C++ integration test.

This commit is contained in:
Guangli Dai 2022-09-16 11:39:34 -07:00 committed by Qi Wang
parent ba19d2cb78
commit c9ac1f4701

View File

@ -10,7 +10,7 @@ typedef void (*abort_hook_t)(const char *message);
bool fake_abort_called;
void fake_abort(const char *message) {
const char *expected_start = "<jemalloc>: Allocation of size";
if (strncmp(message, expected_start, strlen(expected_start) != 0)) {
if (strncmp(message, expected_start, strlen(expected_start)) != 0) {
abort();
}
fake_abort_called = true;
@ -64,4 +64,3 @@ main(void) {
return test(
test_failing_alloc);
}