mirror of
https://github.com/containers/podman.git
synced 2025-06-23 02:18:13 +08:00
fix(specgen): index out of range when unmask=[]
Fixes #18848 Signed-off-by: xtexChooser <xtexchooser@duck.com>
This commit is contained in:
@ -57,7 +57,7 @@ func getCgroupPermissions(unmask []string) string {
|
||||
return ro
|
||||
}
|
||||
|
||||
if unmask != nil && unmask[0] == "ALL" {
|
||||
if unmask != nil && len(unmask) != 0 && unmask[0] == "ALL" {
|
||||
return rw
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user