mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 15:38:40 +01:00
mwan3: fix bugs introduced in 815e83d4
Fixes the following bugs introduced in commit 815e83d4:
- hotplug: invalid parameter order when initial interface state is "online",
mwan3track expects initial state to be the third argument
- hotplug: missing source ip address when initial interface state is "offline"
- mwan3track: source ip address should be the fourth argument
Signed-off-by: Marcin Jurkowski <marcin1j@gmail.com>
This commit is contained in:
@@ -68,13 +68,13 @@ case "$ACTION" in
|
||||
if [ ${running} -eq 1 -a "${status}" = "online" ]; then
|
||||
mwan3_create_iface_rules $INTERFACE $DEVICE
|
||||
mwan3_create_iface_route $INTERFACE $DEVICE
|
||||
mwan3_track $INTERFACE $DEVICE ${src_ip} "online"
|
||||
mwan3_track $INTERFACE $DEVICE "online" "$src_ip"
|
||||
mwan3_set_policies_iptables
|
||||
mwan3_set_user_rules
|
||||
mwan3_flush_conntrack $INTERFACE $DEVICE "ifup"
|
||||
else
|
||||
$LOG notice "Starting tracker on interface $INTERFACE (${DEVICE:-unknown})"
|
||||
mwan3_track $INTERFACE $DEVICE "offline"
|
||||
mwan3_track $INTERFACE $DEVICE "offline" "$src_ip"
|
||||
fi
|
||||
;;
|
||||
ifdown)
|
||||
|
||||
Reference in New Issue
Block a user