Commit 9c327c31 authored by Andrew Vagin's avatar Andrew Vagin Committed by Pavel Emelyanov

zdtm/chroot: wait when a child closes a descriptor

A static test should not change its state during C/R.
Signed-off-by: 's avatarAndrew Vagin <avagin@virtuozzo.com>
Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
parent a57fba05
...@@ -78,6 +78,7 @@ int main(int argc, char **argv) ...@@ -78,6 +78,7 @@ int main(int argc, char **argv)
res = ERR_PIPES; res = ERR_PIPES;
read(pipe_prep[0], &res, 1); read(pipe_prep[0], &res, 1);
read(pipe_prep[0], &res, 1); /* wait when pipe_prep[] will be closed */
if (res != SUCCESS) { if (res != SUCCESS) {
if (res == ERR_PIPES) if (res == ERR_PIPES)
pr_perror("broken pipes"); pr_perror("broken pipes");
......
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