aboutsummaryrefslogtreecommitdiff
path: root/gnu/services
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2019-04-05 17:40:01 +0200
committerLudovic Courtès <ludo@gnu.org>2019-04-05 17:55:50 +0200
commit0cf981a6066711f6e830a3f1d40f7c265b0bac94 (patch)
tree3f82e55ece63fc43d30575ff04cb559dc1670991 /gnu/services
parent37aaf9a8c7d64ae69c4670a12f481dfc0aac53ae (diff)
downloadgnu-guix-0cf981a6066711f6e830a3f1d40f7c265b0bac94.tar
gnu-guix-0cf981a6066711f6e830a3f1d40f7c265b0bac94.tar.gz
services: gdm: Properly handle empty extensions lists.
Fixes a bug whereby not extending GDM would lead us to do: (first '()) in the 'compose' method. Regression introduced in 305a732a0a19c5810aab401aa7d70eba02ac386b. * gnu/services/xorg.scm (gdm-service-type)[compose]: Handle the case where EXTENSIONS is empty. [extend]: Handle the case where XORG-CONFIGURATION is #f.
Diffstat (limited to 'gnu/services')
-rw-r--r--gnu/services/xorg.scm13
1 files changed, 9 insertions, 4 deletions
diff --git a/gnu/services/xorg.scm b/gnu/services/xorg.scm
index 26ca0d4f1f..ede8bc7304 100644
--- a/gnu/services/xorg.scm
+++ b/gnu/services/xorg.scm
@@ -879,11 +879,16 @@ the GNOME desktop environment.")
;; For convenience, this service can be extended with an
;; <xorg-configuration> record. Take the first one that
;; comes.
- (compose first)
+ (compose (lambda (extensions)
+ (match extensions
+ (() #f)
+ ((config . _) config))))
(extend (lambda (config xorg-configuration)
- (gdm-configuration
- (inherit config)
- (xorg-configuration xorg-configuration))))
+ (if xorg-configuration
+ (gdm-configuration
+ (inherit config)
+ (xorg-configuration xorg-configuration))
+ config)))
(default-value (gdm-configuration))
(description