The asserts used in the tests should never be allowed to be optimized away.
printf("<%s>\n", t);
}
printf("<<<%s>>>\n", state);
printf("<%s>\n", t);
}
printf("<<<%s>>>\n", state);
- assert(expected[i] == NULL);
+ assert_se(expected[i] == NULL);
assert_se(isempty(state) == !trailing);
}
assert_se(isempty(state) == !trailing);
}
assert_se(raw_getpid() == parent);
pid = raw_clone(0, NULL);
assert_se(raw_getpid() == parent);
pid = raw_clone(0, NULL);
pid2 = raw_getpid();
log_info("raw_clone: "PID_FMT" getpid()→"PID_FMT" raw_getpid()→"PID_FMT,
pid, getpid(), pid2);
if (pid == 0)
pid2 = raw_getpid();
log_info("raw_clone: "PID_FMT" getpid()→"PID_FMT" raw_getpid()→"PID_FMT,
pid, getpid(), pid2);
if (pid == 0)
- assert(pid2 != parent);
+ assert_se(pid2 != parent);
- assert(pid2 == parent);
+ assert_se(pid2 == parent);
}
int main(int argc, char *argv[]) {
}
int main(int argc, char *argv[]) {