git.99rst.org
/
openwrt-packages.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
| inline |
side by side
(parent:
8d4e202
)
mwan3: do not wait to process ifup/ifdown events
author
Aaron Goodman
<redacted>
Wed, 28 Oct 2020 02:09:36 +0000
(22:09 -0400)
committer
Aaron Goodman
<redacted>
Wed, 28 Oct 2020 03:18:18 +0000
(23:18 -0400)
Signed-off-by: Aaron Goodman <redacted>
net/mwan3/files/usr/sbin/mwan3track
patch
|
blob
|
history
diff --git
a/net/mwan3/files/usr/sbin/mwan3track
b/net/mwan3/files/usr/sbin/mwan3track
index b771e8fced84292f1e1b45a7263de278102a0010..d97933e09ba3378d4f2261cbeca10e43da7e5800 100755
(executable)
--- a/
net/mwan3/files/usr/sbin/mwan3track
+++ b/
net/mwan3/files/usr/sbin/mwan3track
@@
-345,8
+345,12
@@
main() {
get_uptime > $MWAN3TRACK_STATUS_DIR/$INTERFACE/TIME
host_up_count=0
- sleep "${sleep_time}" &
- wait
+ if [ "${IFDOWN_EVENT}" -ne 0 ] && [ "${IFUP_EVENT}" -ne 0 ]; then
+ sleep "${sleep_time}" &
+ SLEEP_PID=$!
+ wait
+ unset SLEEP_PID
+ fi
if [ "${IFDOWN_EVENT}" -eq 1 ]; then
LOG debug "Register ifdown event on interface ${INTERFACE} (${DEVICE})"
git clone https://git.99rst.org/PROJECT