[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
03/03: file-systems: The 'device' field can be a UUID (bytevector).
From: |
Ludovic Courtès |
Subject: |
03/03: file-systems: The 'device' field can be a UUID (bytevector). |
Date: |
Mon, 21 Dec 2015 23:32:16 +0000 |
civodul pushed a commit to branch master
in repository guix.
commit ab64483f648756570f6e9d4027c3b4854e43921c
Author: Ludovic Courtès <address@hidden>
Date: Tue Dec 22 00:29:43 2015 +0100
file-systems: The 'device' field can be a UUID (bytevector).
Previously a wrong-type-arg error would be raised when a file system
with a UUID (bytevector) field was encountered.
* gnu/system.scm (other-file-system-services)[device-mappings]: Check
whether FS's device is a string.
---
gnu/system.scm | 13 ++++++++-----
1 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/gnu/system.scm b/gnu/system.scm
index 2b88214..6f7500f 100644
--- a/gnu/system.scm
+++ b/gnu/system.scm
@@ -192,11 +192,14 @@ as 'needed-for-boot'."
(operating-system-file-systems os)))
(define (device-mappings fs)
- (filter (lambda (md)
- (string=? (string-append "/dev/mapper/"
- (mapped-device-target md))
- (file-system-device fs)))
- (operating-system-mapped-devices os)))
+ (let ((device (file-system-device fs)))
+ (if (string? device)
+ (filter (lambda (md)
+ (string=? (string-append "/dev/mapper/"
+ (mapped-device-target md))
+ device))
+ (operating-system-mapped-devices os))
+ '())))
(define (add-dependencies fs)
;; Add the dependencies due to device mappings to FS.