Crates.io | fslock-guard |
lib.rs | fslock-guard |
version | 0.2.1 |
source | src |
created_at | 2024-02-05 18:40:35.438691 |
updated_at | 2024-12-02 17:52:55.508334 |
description | Wrapper around a lockfile with unlock-on-drop semantics |
homepage | https://gitlab.torproject.org/tpo/core/arti/-/wikis/home |
repository | https://gitlab.torproject.org/tpo/core/arti.git/ |
max_upload_size | |
id | 1127843 |
size | 16,380 |
fslock-guard
— A guard object to ensure we have an exclusive lock to a fileThis crate is a thin wrapper around fslock
, which uses flock
(2) or
LockFileEx
to acquire an advisory lock on the filesystem.
We add two features that fslock
does not (currently) have:
LockFileGuard
] type, which can be used to ensure that a lock is
actually held until the guard is dropped.