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
05a55a40
Commit
05a55a40
authored
Apr 07, 2015
by
Ad Schellevis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cleanup traffic shaper
parent
f89ab7ff
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
10 deletions
+18
-10
shaper.inc
src/etc/inc/shaper.inc
+4
-2
firewall_shaper_vinterface.php
src/www/firewall_shaper_vinterface.php
+14
-8
No files found.
src/etc/inc/shaper.inc
View file @
05a55a40
...
@@ -2965,7 +2965,8 @@ class dnpipe_class extends dummynet_class {
...
@@ -2965,7 +2965,8 @@ class dnpipe_class extends dummynet_class {
foreach
(
$this
->
subqueues
as
$q
)
foreach
(
$this
->
subqueues
as
$q
)
$q
->
delete_queue
();
$q
->
delete_queue
();
unset_dn_object_by_reference
(
$this
->
GetLink
());
unset_dn_object_by_reference
(
$this
->
GetLink
());
@
pfSense_pipe_action
(
"pipe delete "
.
$this
->
GetNumber
());
// TODO: re-enable after kernel fix for dummynet
// @pfSense_pipe_action("pipe delete " . $this->GetNumber());
}
}
function
GetBandwidth
()
{
function
GetBandwidth
()
{
return
$this
->
qbandwidth
;
return
$this
->
qbandwidth
;
...
@@ -3509,7 +3510,8 @@ class dnqueue_class extends dummynet_class {
...
@@ -3509,7 +3510,8 @@ class dnqueue_class extends dummynet_class {
function
delete_queue
()
{
function
delete_queue
()
{
cleanup_dnqueue_from_rules
(
$this
->
GetQname
());
cleanup_dnqueue_from_rules
(
$this
->
GetQname
());
unset_dn_object_by_reference
(
$this
->
GetLink
());
unset_dn_object_by_reference
(
$this
->
GetLink
());
@
pfSense_pipe_action
(
"queue delete "
.
$this
->
GetNumber
());
// TODO: re-enable after kernel fix for dummynet
// @pfSense_pipe_action("queue delete " . $this->GetNumber());
}
}
function
validate_input
(
$data
,
&
$input_errors
)
{
function
validate_input
(
$data
,
&
$input_errors
)
{
...
...
src/www/firewall_shaper_vinterface.php
View file @
05a55a40
...
@@ -48,24 +48,30 @@ read_dummynet_config();
...
@@ -48,24 +48,30 @@ read_dummynet_config();
*/
*/
if
(
$_GET
)
{
if
(
$_GET
)
{
if
(
$_GET
[
'queue'
])
if
(
isset
(
$_GET
[
'queue'
]))
{
$qname
=
htmlspecialchars
(
trim
(
$_GET
[
'queue'
]));
$qname
=
htmlspecialchars
(
trim
(
$_GET
[
'queue'
]));
if
(
$_GET
[
'pipe'
])
}
if
(
isset
(
$_GET
[
'pipe'
]))
{
$pipe
=
htmlspecialchars
(
trim
(
$_GET
[
'pipe'
]));
$pipe
=
htmlspecialchars
(
trim
(
$_GET
[
'pipe'
]));
if
(
$_GET
[
'action'
])
}
if
(
isset
(
$_GET
[
'action'
]))
{
$action
=
htmlspecialchars
(
$_GET
[
'action'
]);
$action
=
htmlspecialchars
(
$_GET
[
'action'
]);
}
}
}
if
(
$_POST
)
{
if
(
$_POST
)
{
if
(
$_POST
[
'name'
])
if
(
isset
(
$_POST
[
'name'
]))
{
$qname
=
htmlspecialchars
(
trim
(
$_POST
[
'name'
]));
$qname
=
htmlspecialchars
(
trim
(
$_POST
[
'name'
]));
else
if
(
$_POST
[
'newname'
])
}
else
if
(
isset
(
$_POST
[
'newname'
]))
{
$qname
=
htmlspecialchars
(
trim
(
$_POST
[
'newname'
]));
$qname
=
htmlspecialchars
(
trim
(
$_POST
[
'newname'
]));
if
(
$_POST
[
'pipe'
])
}
if
(
isset
(
$_POST
[
'pipe'
]))
{
$pipe
=
htmlspecialchars
(
trim
(
$_POST
[
'pipe'
]));
$pipe
=
htmlspecialchars
(
trim
(
$_POST
[
'pipe'
]));
else
}
else
{
$pipe
=
htmlspecialchars
(
trim
(
$qname
));
$pipe
=
htmlspecialchars
(
trim
(
$qname
));
if
(
$_POST
[
'parentqueue'
])
}
if
(
isset
(
$_POST
[
'parentqueue'
]))
{
$parentqueue
=
htmlspecialchars
(
trim
(
$_POST
[
'parentqueue'
]));
$parentqueue
=
htmlspecialchars
(
trim
(
$_POST
[
'parentqueue'
]));
}
}
}
if
(
$pipe
)
{
if
(
$pipe
)
{
...
...
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