Skip to content

Commit

Permalink
Merge pull request opencontainers#2628 from thaJeztah/linting_foo
Browse files Browse the repository at this point in the history
fix some linting issues
  • Loading branch information
AkihiroSuda authored Oct 6, 2020
2 parents 0a9af39 + e8eb800 commit bb539a9
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
1 change: 1 addition & 0 deletions libcontainer/cgroups/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,7 @@ func RemovePaths(paths map[string]string) (err error) {
}
}
if len(paths) == 0 {
//nolint:ineffassign // done to help garbage collecting: opencontainers/runc#2506
paths = make(map[string]string)
return nil
}
Expand Down
1 change: 1 addition & 0 deletions libcontainer/init_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,7 @@ func setupRlimits(limits []configs.Rlimit, pid int) error {

const _P_PID = 1

//nolint:structcheck,unused
type siginfo struct {
si_signo int32
si_errno int32
Expand Down
6 changes: 1 addition & 5 deletions libcontainer/intelrdt/intelrdt.go
Original file line number Diff line number Diff line change
Expand Up @@ -295,11 +295,7 @@ func getIntelRdtRoot() (string, error) {

func isIntelRdtMounted() bool {
_, err := getIntelRdtRoot()
if err != nil {
return false
}

return true
return err == nil
}

type cpuInfoFlags struct {
Expand Down

0 comments on commit bb539a9

Please sign in to comment.