Skip to content

Commit

Permalink
nixos/kresd: Fix unsupported regex
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
griff committed Oct 15, 2020
1 parent b073b54 commit ab94ea6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nixos/modules/services/networking/kresd.nix
Original file line number Diff line number Diff line change
Expand Up @@ -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 ];
Expand Down

0 comments on commit ab94ea6

Please sign in to comment.