mirror of
https://git.proxmox.com/git/pve-common
synced 2025-08-09 05:15:49 +00:00
removed write-only $gateway variable
This commit is contained in:
parent
b1d7951f61
commit
0541ec90f2
@ -764,8 +764,6 @@ sub read_etc_network_interfaces {
|
|||||||
# we try to keep order inside the file
|
# we try to keep order inside the file
|
||||||
my $priority = 2; # 1 is reserved for lo
|
my $priority = 2; # 1 is reserved for lo
|
||||||
|
|
||||||
my $gateway = 0;
|
|
||||||
|
|
||||||
SECTION: while (defined ($line = <$fh>)) {
|
SECTION: while (defined ($line = <$fh>)) {
|
||||||
chomp ($line);
|
chomp ($line);
|
||||||
next if $line =~ m/^\s*#/;
|
next if $line =~ m/^\s*#/;
|
||||||
@ -801,11 +799,8 @@ sub read_etc_network_interfaces {
|
|||||||
} elsif ($line =~ m/^\s*((\S+)\s+(.+))$/) {
|
} elsif ($line =~ m/^\s*((\S+)\s+(.+))$/) {
|
||||||
my $option = $1;
|
my $option = $1;
|
||||||
my ($id, $value) = ($2, $3);
|
my ($id, $value) = ($2, $3);
|
||||||
if (($id eq 'address') || ($id eq 'netmask') || ($id eq 'broadcast')) {
|
if (($id eq 'address') || ($id eq 'netmask') || ($id eq 'broadcast') || ($id eq 'gateway')) {
|
||||||
$d->{$id} = $value;
|
$d->{$id} = $value;
|
||||||
} elsif ($id eq 'gateway') {
|
|
||||||
$d->{$id} = $value;
|
|
||||||
$gateway = 1;
|
|
||||||
} elsif ($id eq 'ovs_type' || $id eq 'ovs_options'|| $id eq 'ovs_bridge' ||
|
} elsif ($id eq 'ovs_type' || $id eq 'ovs_options'|| $id eq 'ovs_bridge' ||
|
||||||
$id eq 'ovs_bonds' || $id eq 'ovs_ports') {
|
$id eq 'ovs_bonds' || $id eq 'ovs_ports') {
|
||||||
$d->{$id} = $value;
|
$d->{$id} = $value;
|
||||||
|
Loading…
Reference in New Issue
Block a user