diff options
author | Christian Poessinger <christian@poessinger.com> | 2020-03-04 08:10:23 +0100 |
---|---|---|
committer | Christian Poessinger <christian@poessinger.com> | 2020-03-04 08:10:23 +0100 |
commit | 5cb485c2fa6e551b9ff8949e9429abd02996cb78 (patch) | |
tree | 877e3be5055294813c9e1f5314fa4edf50070d5a /python/vyos/ifconfig.py | |
parent | 54a932534e0c93611a5676680938c910a9bccb23 (diff) | |
download | vyos-1x-5cb485c2fa6e551b9ff8949e9429abd02996cb78.tar.gz vyos-1x-5cb485c2fa6e551b9ff8949e9429abd02996cb78.zip |
ifconfig: T2057: bugfix KeyError
Error introduced in commit b38dcaf ("ifconfig: T2057: generic interface option
setting").
File "/usr/lib/python3/dist-packages/vyos/ifconfig.py", line 146, in _get_sysfs
filename = self._sysfs_get[name]['location'].format(config)
KeyError: 'ifname'
Diffstat (limited to 'python/vyos/ifconfig.py')
-rw-r--r-- | python/vyos/ifconfig.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/python/vyos/ifconfig.py b/python/vyos/ifconfig.py index beeafa420..389f6072f 100644 --- a/python/vyos/ifconfig.py +++ b/python/vyos/ifconfig.py @@ -143,7 +143,7 @@ class Control: """ Using the defined names, get data write from sysfs. """ - filename = self._sysfs_get[name]['location'].format(config) + filename = self._sysfs_get[name]['location'].format(**config) if not filename: return None return self._read_sysfs(filename) |