1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-26 20:01:15 +02:00

* Make lock removal safe by signalling to blocked processes that the

lock they are waiting on has become stale (we do this by writing a
  meaningless token to the unlinked file).
This commit is contained in:
Eelco Dolstra 2005-01-27 12:19:25 +00:00
parent a24b78e9f1
commit 59682e6188
4 changed files with 52 additions and 21 deletions

View file

@ -415,6 +415,15 @@ bool AutoCloseFD::isOpen()
}
/* Pass responsibility for closing this fd to the caller. */
int AutoCloseFD::borrow()
{
int oldFD = fd;
fd = -1;
return oldFD;
}
void Pipe::create()
{
int fds[2];