Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion net/mwan3/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk

PKG_NAME:=mwan3
PKG_VERSION:=2.12.0
PKG_RELEASE:=3
PKG_RELEASE:=4

PKG_MAINTAINER:=Florian Eckert <[email protected]>
PKG_LICENSE:=GPL-2.0
Expand Down
2 changes: 2 additions & 0 deletions net/mwan3/files/usr/sbin/mwan3track
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,8 @@ main() {
wait $!
}
sleep_time=$interval
network_flush_cache
mwan3_get_src_ip SRC_IP $INTERFACE
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should move the call of network_flush_cache into the function mwan3_get_src_ip. If some in the future needs the function mwan3_get_src_ip anywere else in mwan3. The developer needs to know that the function network_flush_cache needs to be called first to get the latest SRPC_IP value.

We also call this function there

mwan3_get_src_ip src_ip $interface
too.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I disagree with that. The other place where this is used in mwan3track (in firstconnect), there is also the manual call to network_flush_cache. This only refers to a cache within the bash script.

mwan3 use is short running/only calls the function once. Thus, there is no moment where this could be refreshed.

for track_ip in $track_ips; do
if [ $host_up_count -lt $reliability ]; then
case "$track_method" in
Expand Down