Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
OpnSense
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kulya
OpnSense
Commits
3272c7bb
Commit
3272c7bb
authored
Apr 28, 2016
by
Franco Fichtner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
interfaces: different strategy for status porting
parent
10d4cbfd
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
interfaces.inc
src/etc/inc/interfaces.inc
+5
-3
No files found.
src/etc/inc/interfaces.inc
View file @
3272c7bb
...
...
@@ -2699,10 +2699,10 @@ EOD;
}
/* find which clones are up and bring them down */
$ifup
=
legacy_interface_listget
(
'up'
);
$clones_up
=
array
();
foreach
(
$clone_list
as
$clone_if
)
{
$clone_status
=
legacy_interface_stats
(
$clone_if
);
if
(
$clone_status
[
'link state'
]
==
'2'
)
{
if
(
in_array
(
$clone_if
,
$ifup
))
{
$clones_up
[]
=
$clone_if
;
mwexec
(
"
{
$ifconfig
}
"
.
escapeshellarg
(
$clone_if
)
.
" down"
);
}
...
...
@@ -5104,12 +5104,14 @@ function get_interface_info($ifdescr)
$link0
=
'down'
;
}
$ifup
=
legacy_interface_listget
(
'up'
);
$ifinfo
[
'status'
]
=
in_array
(
$chkif
,
$ifup
)
?
'up'
:
'down'
;
$ifinfo
[
'linklocal'
]
=
get_interface_linklocal
(
$ifdescr
);
$ifinfo
[
'ipaddrv6'
]
=
get_interface_ipv6
(
$ifdescr
);
$ifinfo
[
'subnetv6'
]
=
get_interface_subnetv6
(
$ifdescr
);
$ifinfotmp
=
legacy_interface_stats
(
$chkif
);
$ifinfo
[
'status'
]
=
$ifinfotmp
[
'link state'
]
==
'2'
?
'up'
:
'down'
;
$ifinfo
[
'inerrs'
]
=
$ifinfotmp
[
'input errors'
];
$ifinfo
[
'outerrs'
]
=
$ifinfotmp
[
'output errors'
];
$ifinfo
[
'collisions'
]
=
$ifinfotmp
[
'collisions'
];
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment