guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/02: vm: Compute UUIDs truly deterministically.


From: guix-commits
Subject: 02/02: vm: Compute UUIDs truly deterministically.
Date: Tue, 10 Mar 2020 13:18:09 -0400 (EDT)

civodul pushed a commit to branch master
in repository guix.

commit 09844816c77caaa60f4149f99a34733966724627
Author: Ludovic Courtès <address@hidden>
AuthorDate: Tue Mar 10 15:21:48 2020 +0100

    vm: Compute UUIDs truly deterministically.
    
    This is a followup to 1540075c790dfaeff52c93392f2fc63b9e23b77e.
    The mistake had no effect on prior Guile versions but it's visible since
    Guile 3.0.1 and the fix for <https://bugs.gnu.org/39634>.
    
    * gnu/system/vm.scm (operating-system-uuid): Hash a list of
    'file-system-digest' values, not the 'file-system-type' procedure.
---
 gnu/system/vm.scm | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/gnu/system/vm.scm b/gnu/system/vm.scm
index 03a511c..d1c131e 100644
--- a/gnu/system/vm.scm
+++ b/gnu/system/vm.scm
@@ -1,5 +1,5 @@
 ;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovic Courtès 
<address@hidden>
+;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès 
<address@hidden>
 ;;; Copyright © 2016 Christopher Allan Webber <address@hidden>
 ;;; Copyright © 2016, 2017 Leo Famulari <address@hidden>
 ;;; Copyright © 2017 Mathieu Othacehe <address@hidden>
@@ -629,7 +629,8 @@ TYPE (one of 'iso9660 or 'dce).  Return a UUID object."
          'iso9660))
       (bytevector->uuid
        (uint-list->bytevector
-        (list (hash file-system-type
+        (list (hash (map file-system-digest
+                         (operating-system-file-systems os))
                     (- (expt 2 32) 1))
               (hash (operating-system-host-name os)
                     (- (expt 2 32) 1))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]