moby/volume/local
Paweł Gronowski d1aa20efb7
volume: Don't decrement refcount below 0
With both rootless and live restore enabled, there's some race condition
which causes the container to be `Unmount`ed before the refcount is
restored.

This makes sure we don't underflow the refcount (uint64) when
decrementing it.

The root cause of this race condition still needs to be investigated and
fixed, but at least this unflakies the `TestLiveRestore`.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
(cherry picked from commit 294fc9762e)
Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2024-03-08 12:56:41 +01:00
..
local.go volume: Don't decrement refcount below 0 2024-03-08 12:56:41 +01:00
local_linux_test.go volume/local.Create(): validate early 2022-06-03 00:34:21 +02:00
local_test.go volume: fix empty-lines (revive) 2022-09-30 23:59:30 +02:00
local_unix.go volume/local: Don't unmount, restore mounted status 2023-08-29 22:55:59 +02:00
local_windows.go volume/local: Don't unmount, restore mounted status 2023-08-29 22:55:59 +02:00