From 2202812e074afd4248b64c651b50fb743f3ea250 Mon Sep 17 00:00:00 2001 From: Fabricio Voznika Date: Fri, 4 Sep 2020 11:36:41 -0700 Subject: Simplify FD handling for container start/exec VFS1 and VFS2 host FDs have different dupping behavior, making error prone to code for both. Change the contract so that FDs are released as they are used, so the caller can simple defer a block that closes all remaining files. This also addresses handling of partial failures. With this fix, more VFS2 tests can be enabled. Updates #1487 PiperOrigin-RevId: 330112266 --- runsc/boot/BUILD | 2 ++ 1 file changed, 2 insertions(+) (limited to 'runsc/boot/BUILD') diff --git a/runsc/boot/BUILD b/runsc/boot/BUILD index 040f6a72d..704c66742 100644 --- a/runsc/boot/BUILD +++ b/runsc/boot/BUILD @@ -30,6 +30,7 @@ go_library( "//pkg/control/server", "//pkg/cpuid", "//pkg/eventchannel", + "//pkg/fd", "//pkg/fspath", "//pkg/log", "//pkg/memutil", @@ -123,6 +124,7 @@ go_test( library = ":boot", deps = [ "//pkg/control/server", + "//pkg/fd", "//pkg/fspath", "//pkg/log", "//pkg/p9", -- cgit v1.2.3