mirror of
https://github.com/clearlinux/hyperstart.git
synced 2026-09-03 12:11:34 +00:00
send READY a little earlier when creating container
the flush(stdout) is removed, because it is also called in the following code hyper_dup_exec_tty(). Signed-off-by: Lai Jiangshan <jiangshanlai@gmail.com>
This commit is contained in:
+2
-3
@@ -600,6 +600,8 @@ static int hyper_container_init(void *data)
|
||||
goto fail;
|
||||
}
|
||||
|
||||
hyper_send_type(arg->pipe[1], READY);
|
||||
|
||||
if (container->exec.workdir && chdir(container->exec.workdir) < 0) {
|
||||
perror("change work directory failed");
|
||||
return -1;
|
||||
@@ -616,9 +618,6 @@ static int hyper_container_init(void *data)
|
||||
goto fail;
|
||||
}
|
||||
|
||||
hyper_send_type(arg->pipe[1], READY);
|
||||
fflush(stdout);
|
||||
|
||||
if (container_setup_tty(container) < 0) {
|
||||
fprintf(stdout, "setup tty failed\n");
|
||||
goto fail;
|
||||
|
||||
Reference in New Issue
Block a user