Browse Source

daemon: ~PathLocks(): Handle exceptions.

Otherwise, since the call to write a "d" character to the lock file
can fail with ENOSPC, we can get an unhandled exception resulting in a
call to terminate().
version-0.11.0
Eelco Dolstra 6 years ago
committed by Ludovic Courtès
parent
commit
63a5be07e2
No known key found for this signature in database GPG Key ID: 90B11993D9AEBB5
  1. 6
      nix/libstore/pathlocks.cc

6
nix/libstore/pathlocks.cc

@ -162,7 +162,11 @@ bool PathLocks::lockPaths(const PathSet & _paths,
PathLocks::~PathLocks()
{
unlock();
try {
unlock();
} catch (...) {
ignoreException();
}
}

Loading…
Cancel
Save