executor: fix reply status on loop kills

We use exitf on loop failures, anbd exitf is retry-able.
However, we use different status when replying to ipc,
and that different status is what ipc actually uses.
Use kRetryStatus status in case on unexpected loop failures.
This commit is contained in:
Dmitry Vyukov 2017-12-27 08:41:07 +01:00
parent 17f5c9e05f
commit 0c5edf4180

View File

@ -92,7 +92,8 @@ int main(int argc, char** argv)
while (waitpid(-1, &status, __WALL) != pid) {
}
status = WEXITSTATUS(status);
if (status == 0)
// Other statuses happen when fuzzer processes manages to kill loop.
if (status != kFailStatus && status != kErrorStatus)
status = kRetryStatus;
// If an external sandbox process wraps executor, the out pipe will be closed
// before the sandbox process exits this will make ipc package kill the sandbox.