[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
02/09: file-systems: Handle abnormal ‘bcachefs fsck’ exits.
From: |
guix-commits |
Subject: |
02/09: file-systems: Handle abnormal ‘bcachefs fsck’ exits. |
Date: |
Tue, 4 May 2021 09:41:24 -0400 (EDT) |
nckx pushed a commit to branch master
in repository guix.
commit b6269fb7bcd2ef7adfb90b148492bb7a62336f92
Author: Tobias Geerinckx-Rice <me@tobias.gr>
AuthorDate: Tue May 4 11:39:08 2021 +0200
file-systems: Handle abnormal ‘bcachefs fsck’ exits.
* gnu/build/file-systems.scm (check-bcachefs-file-system): Handle a
STATUS:EXIT-VAL of #F.
---
gnu/build/file-systems.scm | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/gnu/build/file-systems.scm b/gnu/build/file-systems.scm
index 6111cd7..23ff25d 100644
--- a/gnu/build/file-systems.scm
+++ b/gnu/build/file-systems.scm
@@ -3,7 +3,7 @@
;;; Copyright © 2016, 2017 David Craven <david@craven.ch>
;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net>
-;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
+;;; Copyright © 2019–2021 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2019 David C. Trudgian <dave@trudgian.net>
;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;;
@@ -264,11 +264,12 @@ bytevector."
"Return the health of a bcachefs file system on DEVICE."
(let ((ignored-bits (logior 2)) ; DEVICE was mounted read-only
(status
+ ;; A number, or #f on abnormal termination (e.g., assertion failure).
(status:exit-val
(apply system* "bcachefs" "fsck" "-p" "-v"
;; Make each multi-device member a separate argument.
(string-split device #\:)))))
- (match (logand (lognot ignored-bits) status)
+ (match (and=> status (cut logand <> (lognot ignored-bits)))
(0 'pass)
(1 'errors-corrected)
(_ 'fatal-error))))
- branch master updated (bee797f -> a49a007), guix-commits, 2021/05/04
- 04/09: gnu: bcachefs-tools: Update to 0.1-6.a14d39d., guix-commits, 2021/05/04
- 05/09: gnu: bcachefs-tools: Prepare for cross-compilation., guix-commits, 2021/05/04
- 02/09: file-systems: Handle abnormal ‘bcachefs fsck’ exits.,
guix-commits <=
- 09/09: gnu: indi: Stop returning #t from phases., guix-commits, 2021/05/04
- 07/09: gnu: indi: Check slightly more functionally., guix-commits, 2021/05/04
- 01/09: gnu: bitcoin-core@0.21: Update to 0.21.1., guix-commits, 2021/05/04
- 03/09: file-systems: Rewrite comment., guix-commits, 2021/05/04
- 08/09: gnu: indi: Respect #:tests?., guix-commits, 2021/05/04
- 06/09: gnu: indi: Update to 1.9.0., guix-commits, 2021/05/04