mirror of
https://github.com/netbirdio/gvisor.git
synced 2026-05-22 17:12:49 -07:00
vfs: try again to allocate a new mount group after resizing vfs.groupIDBitmap
Otherwise, a group id value is always 0x7fffffff in such cases. PiperOrigin-RevId: 580619582
This commit is contained in:
@@ -448,6 +448,10 @@ func (vfs *VirtualFilesystem) allocateGroupID(mnt *Mount) error {
|
||||
if err := vfs.groupIDBitmap.Grow(uint32(vfs.groupIDBitmap.Size())); err != nil {
|
||||
return linuxerr.ENOSPC
|
||||
}
|
||||
groupID, err = vfs.groupIDBitmap.FirstZero(1)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
vfs.groupIDBitmap.Add(groupID)
|
||||
mnt.groupID = groupID
|
||||
|
||||
Reference in New Issue
Block a user