diff options
author | Ludovic Courtès <ludo@gnu.org> | 2015-12-22 00:29:43 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2015-12-22 00:29:43 +0100 |
commit | ab64483f648756570f6e9d4027c3b4854e43921c (patch) | |
tree | 16e13c7e5f215556d110f585611755e2fc26550b /gnu | |
parent | be21979d85304fedd5c0fb970ffc337d220eda7a (diff) | |
download | patches-ab64483f648756570f6e9d4027c3b4854e43921c.tar patches-ab64483f648756570f6e9d4027c3b4854e43921c.tar.gz |
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.
Diffstat (limited to 'gnu')
-rw-r--r-- | gnu/system.scm | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/gnu/system.scm b/gnu/system.scm index 2b8821443a..6f7500f93a 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. |