mirror_iproute2/bridge
Nikolay Aleksandrov 6e982e7b9b bridge: vlan: fix standard stats output
Each of the commits below broke the vlan stats output in a different
way:
- 45fca4ed94 ("bridge: fix vlan show stats formatting")
 Added a second print of an interface name (e.g. eth4eth4)
- c7c1a1ef51 ("bridge: colorize output and use JSON print library")
 Broke normal vlan stats output by not printing a new line after them
 Also printed interfaces without any vlans when printing stats

This fix is not pretty but it brings back the previous behaviour.

Before this fix:
$ bridge -s vlan show
port             vlan id
br0br0              1 PVID Egress Untagged
                   RX: 0 bytes 0 packets
                   TX: 0 bytes 0 packets 4
                   RX: 0 bytes 0 packets
                   TX: 0 bytes 0 packetseth4eth4             4
                   RX: 0 bytes 0 packets
                   TX: 0 bytes 0 packetsroot@debian:~/

After this fix:
$ bridge -s vlan show
port             vlan id
br0              1 PVID Egress Untagged
                   RX: 0 bytes 0 packets
                   TX: 0 bytes 0 packets
                 4
                   RX: 0 bytes 0 packets
                   TX: 0 bytes 0 packets
eth4             4
                   RX: 0 bytes 0 packets
                   TX: 0 bytes 0 packets

Fixes: 45fca4ed94 ("bridge: fix vlan show stats formatting")
Fixes: c7c1a1ef51 ("bridge: colorize output and use JSON print library")
Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
2019-04-17 16:30:05 -07:00
..
.gitignore Add bridge command 2012-08-01 15:23:49 -07:00
br_common.h bridge: mdb: restore valid json output 2019-04-17 16:27:06 -07:00
bridge.c ip bridge: Set NETLINK_GET_STRICT_CHK on socket 2018-12-27 15:36:29 -08:00
fdb.c bridge: fdb: add support for src_vni option 2019-03-05 07:52:34 -08:00
link.c ip: bridge: add mcast to unicast config flag 2019-03-22 09:44:49 -07:00
Makefile SPDX license identifiers 2017-11-24 12:21:35 -08:00
mdb.c bridge: mdb: restore valid json output 2019-04-17 16:27:06 -07:00
monitor.c bridge: mdb: restore valid json output 2019-04-17 16:27:06 -07:00
vlan.c bridge: vlan: fix standard stats output 2019-04-17 16:30:05 -07:00