From: Wolfgang Bumiller Date: Thu, 25 Jun 2015 09:54:29 +0000 (+0200) Subject: read_etc_interfaces: missing iface initialization X-Git-Url: https://git.proxmox.com/?p=pve-common.git;a=commitdiff_plain;h=cb07ff78cab6f6994cc5b6978e52ed65af8869ec read_etc_interfaces: missing iface initialization If no 'auto' line was read the interface hash has to be initialized. --- diff --git a/src/PVE/INotify.pm b/src/PVE/INotify.pm index 630e62f..7fc6978 100644 --- a/src/PVE/INotify.pm +++ b/src/PVE/INotify.pm @@ -827,7 +827,7 @@ sub __read_etc_network_interfaces { my $f = { method => $3 }; # by family, merged to $d with a $suffix (my $suffix = $family) =~ s/^inet//; - my $d = $ifaces->{$i}; + my $d = $ifaces->{$i} ||= {}; $d->{priority} = $priority++ if !$d->{priority}; push @{$d->{families}}, $family;