From 6f888b7530906167ecb1f5a35e060fec736d6d32 Mon Sep 17 00:00:00 2001 From: Cameron Finucane Date: Thu, 12 Sep 2024 17:05:23 -0700 Subject: vm: make sure vm.Pools are cleaned up Add calls to Close() from all locations that call Create(). --- pkg/instance/instance.go | 1 + 1 file changed, 1 insertion(+) (limited to 'pkg/instance/instance.go') diff --git a/pkg/instance/instance.go b/pkg/instance/instance.go index ab79569f9..4c877a229 100644 --- a/pkg/instance/instance.go +++ b/pkg/instance/instance.go @@ -257,6 +257,7 @@ func (env *env) Test(numVMs int, reproSyz, reproOpts, reproC []byte) ([]EnvTestR if err != nil { return nil, fmt.Errorf("failed to create VM pool: %w", err) } + defer vmPool.Close() if n := vmPool.Count(); numVMs > n { numVMs = n } -- cgit mrf-deployment