---
 src/PVE/INotify.pm | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/PVE/INotify.pm b/src/PVE/INotify.pm
index 0dae177..70c34b1 100644
--- a/src/PVE/INotify.pm
+++ b/src/PVE/INotify.pm
@@ -914,6 +914,10 @@ sub __read_etc_network_interfaces {
            my $f = { method => $3 }; # by family, merged to $d with a $suffix
            (my $suffix = $family) =~ s/^inet//;
 
+           foreach my $existing_family (@{$ifaces->{$i}->{'families'}}) {
+               die "interface $i with family $family already exist" if $family 
eq $existing_family;
+           }
+
            my $d = $ifaces->{$i} ||= {};
            $d->{priority} = $priority++ if !$d->{priority};
            push @{$d->{families}}, $family;
-- 
2.11.0

_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to