summaryrefslogtreecommitdiff
path: root/pkg/domain/infra/abi
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2021-07-15 11:11:10 -0400
committerGitHub <noreply@github.com>2021-07-15 11:11:10 -0400
commitd24fc6b84384cbe4188db941ad452f02d3713540 (patch)
tree7f3c98f2ff2e5f389fdb351ca94528e0751a8881 /pkg/domain/infra/abi
parent5d6a36601776fee55ce3d491f96b620aa3b43218 (diff)
parent0007c98ddb3497de0d4c0f349fd07b8d018cb300 (diff)
downloadpodman-d24fc6b84384cbe4188db941ad452f02d3713540.tar.gz
podman-d24fc6b84384cbe4188db941ad452f02d3713540.tar.bz2
podman-d24fc6b84384cbe4188db941ad452f02d3713540.zip
Merge pull request #10939 from Luap99/rootless-cni
Fix race conditions in rootless cni setup
Diffstat (limited to 'pkg/domain/infra/abi')
-rw-r--r--pkg/domain/infra/abi/system.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/pkg/domain/infra/abi/system.go b/pkg/domain/infra/abi/system.go
index ebe59e871..155cda21d 100644
--- a/pkg/domain/infra/abi/system.go
+++ b/pkg/domain/infra/abi/system.go
@@ -403,6 +403,8 @@ func (ic *ContainerEngine) Unshare(ctx context.Context, args []string, options e
if err != nil {
return err
}
+ // make sure to unlock, unshare can run for a long time
+ rootlesscni.Lock.Unlock()
defer rootlesscni.Cleanup(ic.Libpod)
return rootlesscni.Do(unshare)
}