aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2022-06-02 10:55:11 +0200
committerGravatar Christian Hesse <mail@eworm.de>2022-06-02 11:14:36 +0200
commit09d88ad91c62bd00a24ea75d41d340e5bcc2d8b8 (patch)
treeae73e74a1a10cd5c00f30cfab1ecd6bdbd6ca5d1
parent9942918580a486cfabd6bdec8783fc8069372429 (diff)
mod/bridge-port-vlan: show vlan name in log message
-rw-r--r--mod/bridge-port-vlan3
1 files changed, 2 insertions, 1 deletions
diff --git a/mod/bridge-port-vlan b/mod/bridge-port-vlan
index 13352b5..efdaab8 100644
--- a/mod/bridge-port-vlan
+++ b/mod/bridge-port-vlan
@@ -36,6 +36,7 @@
/ip/dhcp-client/enable $DHCPClient;
}
} else={
+ :local VlanName $Vlan;
:if ($Vlan != [ :tostr [ :tonum $Vlan ] ]) do={
:do {
:set $Vlan ([ /interface/bridge/vlan/get [ find where comment=$Vlan ] vlan-ids ]->0);
@@ -45,7 +46,7 @@
}
:if ($BridgePortVal->"disabled" = true || $Vlan != $BridgePortVal->"pvid") do={
$LogPrintExit2 info $0 ("Enabling bridge port for interface " . $BridgePortVal->"interface" . ", changing to " . $ConfigTo . \
- " vlan " . $Vlan . ", disabling dhcp client.") false;
+ " vlan " . $Vlan . [ $IfThenElse ($Vlan != $VlanName) (" (" . $VlanName . ")") ] . ", disabling dhcp client.") false;
:if ([ :len $DHCPClient ] = 1) do={
/ip/dhcp-client/disable $DHCPClient;
:delay 200ms;