mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-02-14 19:41:51 +00:00
Fix error in omr-dscp and allow - in port range
This commit is contained in:
parent
746927113b
commit
8ed49706ac
1 changed files with 8 additions and 6 deletions
|
@ -81,6 +81,8 @@ _add_dscp_rules() {
|
|||
direction="" ; config_get direction "$1" direction "upload"
|
||||
comment="" ; config_get comment "$1" comment "-"
|
||||
|
||||
src_port="$(echo $src_port | sed 's/-/:)"
|
||||
dest_port="$(echo $dest_port | sed 's/-/:)"
|
||||
case "$direction" in
|
||||
upload|both)
|
||||
# Apply the rule locally
|
||||
|
@ -142,28 +144,28 @@ _add_dscp_output_chain() {
|
|||
_remove_prerouting_chain() {
|
||||
_ipt4 -F "$1" 2>/dev/null || return
|
||||
_ipt4 -D PREROUTING -i "$lan_device" -j "$1"
|
||||
_ipt4 -X "$1"
|
||||
_ipt4 -X "$1" 2>/dev/null
|
||||
_ipt6 -F "$1" 2>/dev/null || return
|
||||
_ipt6 -D PREROUTING -i "$lan_device" -j "$1"
|
||||
_ipt6 -X "$1"
|
||||
_ipt6 -X "$1" 2>/dev/null
|
||||
}
|
||||
|
||||
_remove_postrouting_chain() {
|
||||
_ipt4 -F "$1" 2>/dev/null || return
|
||||
_ipt4 -D POSTROUTING -j "$1"
|
||||
_ipt4 -X "$1"
|
||||
_ipt4 -X "$1" 2>/dev/null
|
||||
_ipt6 -F "$1" 2>/dev/null || return
|
||||
_ipt6 -D POSTROUTING -j "$1"
|
||||
_ipt6 -X "$1"
|
||||
_ipt6 -X "$1" 2>/dev/null
|
||||
}
|
||||
|
||||
_remove_output_chain() {
|
||||
_ipt4 -F "$1" 2>/dev/null || return
|
||||
_ipt4 -D OUTPUT -j "$1"
|
||||
_ipt4 -X "$1"
|
||||
_ipt4 -X "$1" 2>/dev/null
|
||||
_ipt6 -F "$1" 2>/dev/null || return
|
||||
_ipt6 -D OUTPUT -j "$1"
|
||||
_ipt6 -X "$1"
|
||||
_ipt6 -X "$1" 2>/dev/null
|
||||
}
|
||||
|
||||
_remove_ipset_dnsmasq() {
|
||||
|
|
Loading…
Reference in a new issue