mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-24 21:38:07 -05:00
linux-boot: Don't fail if /root/etc/mtab is a dangling symlink.
Reported Joshua Grant. Patch suggested by Mark H Weaver. * gnu/build/linux-boot.scm (mount-root-file-system): Use 'false-if-exception' instead of 'when (file-exists? ...)' to account for dangling symlinks.
This commit is contained in:
parent
9250b30466
commit
01ed3c4fe5
1 changed files with 2 additions and 2 deletions
|
@ -1,5 +1,5 @@
|
|||
;;; GNU Guix --- Functional package management for GNU
|
||||
;;; Copyright © 2013, 2014 Ludovic Courtès <ludo@gnu.org>
|
||||
;;; Copyright © 2013, 2014, 2015 Ludovic Courtès <ludo@gnu.org>
|
||||
;;;
|
||||
;;; This file is part of GNU Guix.
|
||||
;;;
|
||||
|
@ -276,7 +276,7 @@ (define (mark-as-not-killable pid)
|
|||
(mount root "/root" type)))
|
||||
|
||||
;; Make sure /root/etc/mtab is a symlink to /proc/self/mounts.
|
||||
(when (file-exists? "/root/etc/mtab")
|
||||
(false-if-exception
|
||||
(delete-file "/root/etc/mtab"))
|
||||
(symlink "/proc/self/mounts" "/root/etc/mtab"))
|
||||
|
||||
|
|
Loading…
Reference in a new issue