From ab94ea66fae3aba48151f0e2243b2317378cd128 Mon Sep 17 00:00:00 2001 From: Brian Olsen Date: Thu, 15 Oct 2020 14:37:04 +0200 Subject: [PATCH] nixos/kresd: Fix unsupported regex Regex supported by `builtins.match` differ on Linux and Darwin (see NixOS/Nix#1537) and the empty match group errors on Darwin. But simply removing it does not change the logic in the module in any way. --- nixos/modules/services/networking/kresd.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/services/networking/kresd.nix b/nixos/modules/services/networking/kresd.nix index ccb34163d5f3..bdadc5970e62 100644 --- a/nixos/modules/services/networking/kresd.nix +++ b/nixos/modules/services/networking/kresd.nix @@ -10,7 +10,7 @@ let mkListen = kind: addr: let al_v4 = builtins.match "([0-9.]\+):([0-9]\+)" addr; al_v6 = builtins.match "\\[(.\+)]:([0-9]\+)" addr; - al_portOnly = builtins.match "()([0-9]\+)" addr; + al_portOnly = builtins.match "([0-9]\+)" addr; al = findFirst (a: a != null) (throw "services.kresd.*: incorrect address specification '${addr}'") [ al_v4 al_v6 al_portOnly ];