diff options
Diffstat (limited to 'pkg/specgen/pod_validate.go')
-rw-r--r-- | pkg/specgen/pod_validate.go | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/pkg/specgen/pod_validate.go b/pkg/specgen/pod_validate.go index 98d59549e..08f1c0300 100644 --- a/pkg/specgen/pod_validate.go +++ b/pkg/specgen/pod_validate.go @@ -33,7 +33,7 @@ func (p *PodSpecGenerator) Validate() error { } // PodNetworkConfig - if err := p.NetNS.validate(); err != nil { + if err := validateNetNS(&p.NetNS); err != nil { return err } if p.NoInfra { @@ -85,10 +85,6 @@ func (p *PodSpecGenerator) Validate() error { return exclusivePodOptions("NoManageHosts", "HostAdd") } - if err := p.NetNS.validate(); err != nil { - return err - } - // Set Defaults if p.NetNS.Value == "" { if rootless.IsRootless() { |