guix-commits
[Top][All Lists]
Advanced

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

03/09: environment: Suggestion code gracefully handles empty "/bin" dire


From: guix-commits
Subject: 03/09: environment: Suggestion code gracefully handles empty "/bin" directories.
Date: Fri, 10 Dec 2021 09:33:39 -0500 (EST)

civodul pushed a commit to branch master
in repository guix.

commit 16e9e538386bf30da690502c65b8053ff266e8cb
Author: Ludovic Courtès <ludo@gnu.org>
AuthorDate: Fri Dec 10 12:27:58 2021 +0100

    environment: Suggestion code gracefully handles empty "/bin" directories.
    
    * guix/scripts/environment.scm (suggest-command-name): Handle the case
    where 'scandir' returns #f.
---
 guix/scripts/environment.scm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm
index 821f20e..510cee7 100644
--- a/guix/scripts/environment.scm
+++ b/guix/scripts/environment.scm
@@ -567,7 +567,7 @@ command name."
       (_ #t)))
 
   (match (scandir (string-append profile "/bin") not-dot?)
-    (() #f)
+    ((or #f ()) #f)
     (available
      (match command
        ((executable _ ...)



reply via email to

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