From d80398b6542b24042961ff6eae657c58c98d93c3 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Tue, 24 Sep 2019 18:10:39 +0200 Subject: Python/ifconfig: T1557: refactor 'mac' property to set_mac() --- src/conf_mode/interface-ethernet.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/conf_mode/interface-ethernet.py') diff --git a/src/conf_mode/interface-ethernet.py b/src/conf_mode/interface-ethernet.py index 43e598618..7708c0086 100755 --- a/src/conf_mode/interface-ethernet.py +++ b/src/conf_mode/interface-ethernet.py @@ -74,7 +74,7 @@ def apply_vlan_config(vlan, config): vlan.set_mtu(config['mtu']) # Change VLAN interface MAC address if config['mac']: - vlan.mac = config['mac'] + vlan.set_mac(config['mac']) # enable/disable VLAN interface if config['disable']: @@ -291,9 +291,9 @@ def apply(eth): # Change interface MAC address - re-set to real hardware address (hw-id) # if custom mac is removed if eth['mac']: - e.mac = eth['mac'] + e.set_mac(eth['mac']) else: - e.mac = eth['hw_id'] + e.set_mac(eth['hw_id']) # Maximum Transmission Unit (MTU) e.set_mtu(eth['mtu']) -- cgit v1.2.3