Re: [PATCH 3/4] libqtest: ensure waitpid() is only called once

2023-01-31 Thread Thomas Huth
On 17/01/2023 09.07, Paolo Bonzini wrote: If a test aborts after qtest_wait_qemu() is called, the SIGABRT hooks are still in place and waitpid() is called again. The second time it is called, the process does not exist anymore and the system call fails. Move the s->qemu_pid = -1 assignment to q

[PATCH 3/4] libqtest: ensure waitpid() is only called once

2023-01-17 Thread Paolo Bonzini
If a test aborts after qtest_wait_qemu() is called, the SIGABRT hooks are still in place and waitpid() is called again. The second time it is called, the process does not exist anymore and the system call fails. Move the s->qemu_pid = -1 assignment to qtest_wait_qemu() to make it idempotent, and