Fix free-disk-space call

As the WAL file might not exist.
This commit is contained in:
Christopher Baines 2024-10-13 19:12:09 +01:00
parent c04ea067c2
commit 46b86761f5

View file

@ -1771,7 +1771,7 @@ SELECT 1 FROM derivation_source_file_nars WHERE derivation_source_file_id = $1"
(max (max
(* 4096 (expt 2 20)) (* 4096 (expt 2 20))
(* 0.8 (* 0.8
(- (free-disk-space "/var/guix/db/db.sqlite-wal") (- (free-disk-space "/var/guix/db/db.sqlite")
(get-wal-bytes))))) (get-wal-bytes)))))
(if (< (get-wal-bytes) threshold) (if (< (get-wal-bytes) threshold)