summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2022-05-26 08:10:23 +0200
committerGitHub <noreply@github.com>2022-05-26 08:10:23 +0200
commit9854c72dfc8c88c9b1c0b21637091216aed94baa (patch)
tree9f9d82baf4fce986c32b7f01c897cd8427617ed8
parentd458ded452d90910ad670623534dd3f017603a6b (diff)
parent1a1aa4b5e509566339cd9b8d1372e0cf526eb2ee (diff)
downloadvyos-1x-9854c72dfc8c88c9b1c0b21637091216aed94baa.tar.gz
vyos-1x-9854c72dfc8c88c9b1c0b21637091216aed94baa.zip
Merge pull request #1332 from c-po/t4441-equuleus-wwan
T4441: wwan: connection not possible after a change added after 1.3.1-S1 release - equuleus
-rwxr-xr-xsrc/conf_mode/interfaces-wwan.py20
1 files changed, 9 insertions, 11 deletions
diff --git a/src/conf_mode/interfaces-wwan.py b/src/conf_mode/interfaces-wwan.py
index a1a9360d7..179d1efb4 100755
--- a/src/conf_mode/interfaces-wwan.py
+++ b/src/conf_mode/interfaces-wwan.py
@@ -21,7 +21,7 @@ from time import sleep
from vyos.config import Config
from vyos.configdict import get_interface_dict
-from vyos.configdict import leaf_node_changed
+from vyos.configdict import is_node_changed
from vyos.configverify import verify_authentication
from vyos.configverify import verify_interface_exists
from vyos.configverify import verify_vrf
@@ -54,27 +54,25 @@ def get_config(config=None):
# We should only terminate the WWAN session if critical parameters change.
# All parameters that can be changed on-the-fly (like interface description)
# should not lead to a reconnect!
- tmp = leaf_node_changed(conf, ['address'])
+ tmp = is_node_changed(conf, ['address'])
if tmp: wwan.update({'shutdown_required': {}})
- tmp = leaf_node_changed(conf, ['apn'])
+ tmp = is_node_changed(conf, ['apn'])
if tmp: wwan.update({'shutdown_required': {}})
- tmp = leaf_node_changed(conf, ['disable'])
+ tmp = is_node_changed(conf, ['disable'])
if tmp: wwan.update({'shutdown_required': {}})
- tmp = leaf_node_changed(conf, ['vrf'])
- # leaf_node_changed() returns a list, as VRF is a non-multi node, there
- # will be only one list element
- if tmp: wwan.update({'vrf_old': tmp[0]})
+ tmp = is_node_changed(conf, ['vrf'])
+ if tmp: wwan.update({'vrf_old': {}})
- tmp = leaf_node_changed(conf, ['authentication', 'user'])
+ tmp = is_node_changed(conf, ['authentication', 'user'])
if tmp: wwan.update({'shutdown_required': {}})
- tmp = leaf_node_changed(conf, ['authentication', 'password'])
+ tmp = is_node_changed(conf, ['authentication', 'password'])
if tmp: wwan.update({'shutdown_required': {}})
- tmp = leaf_node_changed(conf, ['ipv6', 'address', 'autoconf'])
+ tmp = is_node_changed(conf, ['ipv6', 'address', 'autoconf'])
if tmp: wwan.update({'shutdown_required': {}})
# We need to know the amount of other WWAN interfaces as ModemManager needs