diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2022-04-25 13:43:57 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-25 13:43:57 -0400 |
commit | 09ef4f2e226c0bd769c93817fa5a4df1a9bb9f8b (patch) | |
tree | 1d8b6afb20e8b48f9193d4897162c3a1d24dbd4a /pkg/specgenutil | |
parent | 23d2bf518884df59f7177099d07b11b1ca344a2f (diff) | |
parent | c7b16645aff27fff0b87bb2a98298693bbf20894 (diff) | |
download | podman-09ef4f2e226c0bd769c93817fa5a4df1a9bb9f8b.tar.gz podman-09ef4f2e226c0bd769c93817fa5a4df1a9bb9f8b.tar.bz2 podman-09ef4f2e226c0bd769c93817fa5a4df1a9bb9f8b.zip |
Merge pull request #13978 from Luap99/unparam
enable unparam linter
Diffstat (limited to 'pkg/specgenutil')
-rw-r--r-- | pkg/specgenutil/specgen.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/specgenutil/specgen.go b/pkg/specgenutil/specgen.go index 00de99817..f0dfcac1a 100644 --- a/pkg/specgenutil/specgen.go +++ b/pkg/specgenutil/specgen.go @@ -136,7 +136,7 @@ func LimitToSwap(memory *specs.LinuxMemory, swap string, ml int64) { } } -func getMemoryLimits(s *specgen.SpecGenerator, c *entities.ContainerCreateOptions) (*specs.LinuxMemory, error) { +func getMemoryLimits(c *entities.ContainerCreateOptions) (*specs.LinuxMemory, error) { var err error memory := &specs.LinuxMemory{} hasLimits := false @@ -497,7 +497,7 @@ func FillOutSpecGen(s *specgen.SpecGenerator, c *entities.ContainerCreateOptions } if s.ResourceLimits.Memory == nil || (len(c.Memory) != 0 || len(c.MemoryReservation) != 0 || len(c.MemorySwap) != 0 || c.MemorySwappiness != 0) { - s.ResourceLimits.Memory, err = getMemoryLimits(s, c) + s.ResourceLimits.Memory, err = getMemoryLimits(c) if err != nil { return err } |