aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr/eval-cache.cc
diff options
context:
space:
mode:
authorRobert Hensing <robert@roberthensing.nl>2022-02-06 13:25:56 +0100
committerRobert Hensing <robert@roberthensing.nl>2022-02-06 13:53:28 +0100
commitc3b942e0fc4777f9033f614b6b1f462c0f8c473e (patch)
tree95ea9621578abb0c14b45f228d8e56e7a888349d /src/libexpr/eval-cache.cc
parent4369771870b3945f95e1468a0803696034d506b7 (diff)
Don't hold interruptCallbacks lock during interrupt handling
This changes the representation of the interrupt callback list to be safe to use during interrupt handling. Holding a lock while executing arbitrary functions is something to avoid in general, because of the risk of deadlock. Such a deadlock occurs in https://github.com/NixOS/nix/issues/3294 where ~CurlDownloader tries to deregister its interrupt callback. This happens during what seems to be a triggerInterrupt() by the daemon connection's MonitorFdHup thread. This bit I can not confirm based on the stack trace though; it's based on reading the code, so no absolute certainty, but a smoking gun nonetheless.
Diffstat (limited to 'src/libexpr/eval-cache.cc')
0 files changed, 0 insertions, 0 deletions