mirror of
https://github.com/NixOS/nix.git
synced 2024-11-25 00:02:25 +00:00
Make sure that pdiGcDaemon
is the right pid
Move its definition before a loop that might change `$!`
This commit is contained in:
parent
e859565a20
commit
1dbba94244
@ -163,11 +163,11 @@ startGcDaemon() {
|
||||
-s "$NIX_STORE_DIR" \
|
||||
> /dev/null 2>&1 \
|
||||
&
|
||||
pidGcDaemon=$!
|
||||
for ((i = 0; i < 30; i++)); do
|
||||
if [[ -S $NIX_GC_SOCKET_PATH ]]; then break; fi
|
||||
sleep 1
|
||||
done
|
||||
pidGcDaemon=$!
|
||||
trapFunctions[killGcDaemon]=killGcDaemon
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user