#pragma once #include "types.hh" namespace nix { /* Open (possibly create) a lock file and return the file descriptor. -1 is returned if create is false and the lock could not be opened because it doesn't exist. Any other error throws an exception. */ int openLockFile(const Path & path, bool create); /* Delete an open lock file. */ void deleteLockFile(const Path & path, int fd); enum LockType { ltRead, ltWrite, ltNone }; bool lockFile(int fd, LockType lockType, bool wait); class PathLocks { private: typedef std::pair FDPair; list fds; bool deletePaths; public: PathLocks(); PathLocks(const PathSet & paths, const string & waitMsg = ""); bool lockPaths(const PathSet & _paths, const string & waitMsg = "", bool wait = true); ~PathLocks(); void unlock(); void setDeletion(bool deletePaths); }; bool pathIsLockedByMe(const Path & path); } ct> Wojtek's customized Guix
aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author宋文武 <iyzsong@member.fsf.org>2023-07-29 10:53:19 +0800
committer宋文武 <iyzsong@member.fsf.org>2023-08-03 17:38:10 +0800
commitfe638b48e9204fd736908467c21e1d2a95828701 (patch)
tree2fc8fd122d1a0bef358e345ee1b3911ef31119bf /gnu/packages/enlightenment.scm
parentc5fe3b199147205a091980919cd49e2b484e17e2 (diff)
downloadguix-fe638b48e9204fd736908467c21e1d2a95828701.tar.gz
guix-fe638b48e9204fd736908467c21e1d2a95828701.zip
gnu: granatier: Update to 23.04.3.
* gnu/packages/kde-games.scm (granatier): Update to 23.04.3.
Diffstat (limited to 'gnu/packages/enlightenment.scm')
0 files changed, 0 insertions, 0 deletions