summaryrefslogtreecommitdiff
path: root/libpod/container_internal_linux.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2022-04-22 08:26:31 -0400
committerGitHub <noreply@github.com>2022-04-22 08:26:31 -0400
commit22500d797aba09eada894a69ad88f2699a560d02 (patch)
tree009b712a567ee4fd25fb4e8961e47cb0a4c8e684 /libpod/container_internal_linux.go
parent04acbaa4b161b23e93b990321582b1586d86f2a8 (diff)
parent1514d5c933510228dfa8bb9b6c020af3f266060f (diff)
downloadpodman-22500d797aba09eada894a69ad88f2699a560d02.tar.gz
podman-22500d797aba09eada894a69ad88f2699a560d02.tar.bz2
podman-22500d797aba09eada894a69ad88f2699a560d02.zip
Merge pull request #13972 from Luap99/staticcheck
enable staticcheck linter
Diffstat (limited to 'libpod/container_internal_linux.go')
-rw-r--r--libpod/container_internal_linux.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/libpod/container_internal_linux.go b/libpod/container_internal_linux.go
index f8d0a124c..6ffd99649 100644
--- a/libpod/container_internal_linux.go
+++ b/libpod/container_internal_linux.go
@@ -399,6 +399,9 @@ func (c *Container) generateSpec(ctx context.Context) (*spec.Spec, error) {
}
}
+ // NewFromSpec() is deprecated according to its comment
+ // however the recommended replace just causes a nil map panic
+ //nolint:staticcheck
g := generate.NewFromSpec(c.config.Spec)
// If network namespace was requested, add it now
@@ -1520,6 +1523,10 @@ func (c *Container) checkpoint(ctx context.Context, options ContainerCheckpointO
func (c *Container) generateContainerSpec() error {
// Make sure the newly created config.json exists on disk
+
+ // NewFromSpec() is deprecated according to its comment
+ // however the recommended replace just causes a nil map panic
+ //nolint:staticcheck
g := generate.NewFromSpec(c.config.Spec)
if err := c.saveSpec(g.Config); err != nil {