tc/m_vlan: fix print_vlan() conditional on TCA_VLAN_ACT_PUSH_ETH

Fix the wild bracket in the if clause leading to the error in the condition.

Fixes: d61167dd88 ("m_vlan: add pop_eth and push_eth actions")
Signed-off-by: Maxim Petrov <mmrmaximuzz@gmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
This commit is contained in:
Maxim Petrov 2021-11-17 21:05:33 +03:00 committed by Stephen Hemminger
parent 9bd5ab0f09
commit 0e94972590
1 changed files with 2 additions and 2 deletions

View File

@ -279,8 +279,8 @@ static int print_vlan(struct action_util *au, FILE *f, struct rtattr *arg)
ETH_ALEN, 0, b1, sizeof(b1)); ETH_ALEN, 0, b1, sizeof(b1));
print_string(PRINT_ANY, "dst_mac", " dst_mac %s", b1); print_string(PRINT_ANY, "dst_mac", " dst_mac %s", b1);
} }
if (tb[TCA_VLAN_PUSH_ETH_SRC && if (tb[TCA_VLAN_PUSH_ETH_SRC] &&
RTA_PAYLOAD(tb[TCA_VLAN_PUSH_ETH_SRC]) == ETH_ALEN]) { RTA_PAYLOAD(tb[TCA_VLAN_PUSH_ETH_SRC]) == ETH_ALEN) {
ll_addr_n2a(RTA_DATA(tb[TCA_VLAN_PUSH_ETH_SRC]), ll_addr_n2a(RTA_DATA(tb[TCA_VLAN_PUSH_ETH_SRC]),
ETH_ALEN, 0, b1, sizeof(b1)); ETH_ALEN, 0, b1, sizeof(b1));
print_string(PRINT_ANY, "src_mac", " src_mac %s", b1); print_string(PRINT_ANY, "src_mac", " src_mac %s", b1);