net/mwan3: add mwan3_init function

Move all shell commands which are executed during /lib/mwan3/mwan3.sh
sourceing into a seperate init function which must be called at first.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
This commit is contained in:
Florian Eckert
2018-02-02 14:56:18 +01:00
parent 7cf9d9ec20
commit 8fa2101ea3
3 changed files with 36 additions and 19 deletions

View File

@@ -187,6 +187,7 @@ restart() {
case "$1" in
ifup|ifdown|interfaces|policies|connected|rules|status|start|stop|restart)
mwan3_init
$*
;;
*)