oci/caps: rename some vars that conflicted with imports / built-ins
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
parent
94334153b5
commit
b00b21b93c
1 changed files with 6 additions and 6 deletions
|
@ -12,14 +12,14 @@ var capabilityList Capabilities
|
|||
|
||||
func init() {
|
||||
last := capability.CAP_LAST_CAP
|
||||
for _, cap := range capability.List() {
|
||||
if cap > last {
|
||||
for _, c := range capability.List() {
|
||||
if c > last {
|
||||
continue
|
||||
}
|
||||
capabilityList = append(capabilityList,
|
||||
&CapabilityMapping{
|
||||
Key: "CAP_" + strings.ToUpper(cap.String()),
|
||||
Value: cap,
|
||||
Key: "CAP_" + strings.ToUpper(c.String()),
|
||||
Value: c,
|
||||
},
|
||||
)
|
||||
}
|
||||
|
@ -46,8 +46,8 @@ func (c *CapabilityMapping) String() string {
|
|||
// GetAllCapabilities returns all of the capabilities
|
||||
func GetAllCapabilities() []string {
|
||||
output := make([]string, len(capabilityList))
|
||||
for i, capability := range capabilityList {
|
||||
output[i] = capability.String()
|
||||
for i, c := range capabilityList {
|
||||
output[i] = c.String()
|
||||
}
|
||||
return output
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue