Merge pull request #275485 from Ex-32/binfmt-emulatedsystems-fix

nixos/binfmt: added assertion to prevent emulation of current system

Changed files
+1 -1
nixos
modules
system
boot
+1 -1
nixos/modules/system/boot/binfmt.nix
···
};
config = {
-
boot.binfmt.registrations = builtins.listToAttrs (map (system: {
name = system;
value = { config, ... }: let
interpreter = getEmulator system;
···
};
config = {
+
boot.binfmt.registrations = builtins.listToAttrs (map (system: assert system != pkgs.system; {
name = system;
value = { config, ... }: let
interpreter = getEmulator system;