aboutsummaryrefslogtreecommitdiff
path: root/src/libstore/pathlocks.hh
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2018-10-04 15:03:03 +0200
committerEelco Dolstra <edolstra@gmail.com>2019-08-02 18:39:16 +0200
commite349f2c0a370e4dfd09ae51c2cae4db08a834ad5 (patch)
tree5eed56eba53bbeae7b06beec4e021c3922b64528 /src/libstore/pathlocks.hh
parentec415d7166d607c92cf8f1af688f86e4b4731dff (diff)
Use BSD instead of POSIX file locks
POSIX file locks are essentially incompatible with multithreading. BSD locks have much saner semantics. We need this now that there can be multiple concurrent LocalStore::buildPaths() invocations.
Diffstat (limited to 'src/libstore/pathlocks.hh')
-rw-r--r--src/libstore/pathlocks.hh4
1 files changed, 0 insertions, 4 deletions
diff --git a/src/libstore/pathlocks.hh b/src/libstore/pathlocks.hh
index db51f950a..411da0222 100644
--- a/src/libstore/pathlocks.hh
+++ b/src/libstore/pathlocks.hh
@@ -16,8 +16,6 @@ enum LockType { ltRead, ltWrite, ltNone };
bool lockFile(int fd, LockType lockType, bool wait);
-MakeError(AlreadyLocked, Error);
-
class PathLocks
{
private:
@@ -37,6 +35,4 @@ public:
void setDeletion(bool deletePaths);
};
-bool pathIsLockedByMe(const Path & path);
-
}