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
a84ff2b1
Commit
a84ff2b1
authored
Mar 31, 2015
by
Ad Schellevis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove unused functions gwlb.inc
parent
3922acc3
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
43 deletions
+0
-43
gwlb.inc
src/etc/inc/gwlb.inc
+0
-43
No files found.
src/etc/inc/gwlb.inc
View file @
a84ff2b1
...
@@ -900,22 +900,6 @@ function return_gateway_groups_array() {
...
@@ -900,22 +900,6 @@ function return_gateway_groups_array() {
return
(
$gateway_groups_array
);
return
(
$gateway_groups_array
);
}
}
/* Update DHCP WAN Interface ip address in gateway group item */
function
dhclient_update_gateway_groups_defaultroute
(
$interface
=
"wan"
)
{
global
$config
,
$g
;
foreach
(
$config
[
'gateways'
][
'gateway_item'
]
as
&
$gw
)
{
if
(
$gw
[
'interface'
]
==
$interface
)
{
$current_gw
=
get_interface_gateway
(
$interface
);
if
(
$gw
[
'gateway'
]
<>
$current_gw
)
{
$gw
[
'gateway'
]
=
$current_gw
;
$changed
=
true
;
}
}
}
if
(
$changed
&&
$current_gw
)
write_config
(
sprintf
(
gettext
(
'Updating gateway group gateway for %1$s - new gateway is %2$s'
),
$interfac
,
$current_gw
));
}
function
lookup_gateway_ip_by_name
(
$name
)
{
function
lookup_gateway_ip_by_name
(
$name
)
{
$gateways_arr
=
return_gateways_array
(
false
,
true
);
$gateways_arr
=
return_gateways_array
(
false
,
true
);
...
@@ -1060,33 +1044,6 @@ function validate_address_family($ipaddr, $gwname) {
...
@@ -1060,33 +1044,6 @@ function validate_address_family($ipaddr, $gwname) {
return
false
;
return
false
;
}
}
/* check if a interface is part of a gateway group */
function
interface_gateway_group_member
(
$interface
)
{
global
$config
;
if
(
is_array
(
$config
[
'gateways'
][
'gateway_group'
]))
$groups
=
$config
[
'gateways'
][
'gateway_group'
];
else
return
false
;
$gateways_arr
=
return_gateways_array
(
false
,
true
);
foreach
(
$groups
as
$group
)
{
if
(
is_array
(
$group
[
'item'
]))
{
foreach
(
$group
[
'item'
]
as
$item
)
{
$elements
=
explode
(
"|"
,
$item
);
$gwname
=
$elements
[
0
];
if
(
$interface
==
$gateways_arr
[
$gwname
][
'interface'
])
{
unset
(
$gateways_arr
);
return
true
;
}
}
}
}
unset
(
$gateways_arr
);
return
false
;
}
function
gateway_is_gwgroup_member
(
$name
)
{
function
gateway_is_gwgroup_member
(
$name
)
{
global
$config
;
global
$config
;
...
...
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