mirror of
https://github.com/containers/podman.git
synced 2025-10-18 03:33:32 +08:00
Add initial version of renumber backend
Renumber is a way of renumbering container locks after the number of locks available has changed. For now, renumber only works with containers. Signed-off-by: Matthew Heon <matthew.heon@pm.me>
This commit is contained in:
@ -89,3 +89,12 @@ func (m *InMemoryManager) RetrieveLock(id uint32) (Locker, error) {
|
||||
|
||||
return m.locks[id], nil
|
||||
}
|
||||
|
||||
// FreeAllLocks frees all locks
|
||||
func (m *InMemoryManager) FreeAllLocks() error {
|
||||
for _, lock := range m.locks {
|
||||
lock.allocated = false
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user