diff --git a/src/vmspawn/vmspawn.c b/src/vmspawn/vmspawn.c index a136ae4c3c..5341699b79 100644 --- a/src/vmspawn/vmspawn.c +++ b/src/vmspawn/vmspawn.c @@ -696,6 +696,9 @@ static int run_virtual_machine(void) { _exit(EXIT_FAILURE); } + /* Close the vsock fd we passed to qemu in the parent. We don't need it anymore. */ + child_vsock_fd = safe_close(child_vsock_fd); + int exit_status = INT_MAX; if (use_vsock) { r = setup_notify_parent(event, vsock_fd, &exit_status, ¬ify_event_source);