Skip to content

Commit 7cbaac0

Browse files
committed
Add failing test case to reproduce the parse bug
1 parent 83ef039 commit 7cbaac0

File tree

1 file changed

+21
-16
lines changed

1 file changed

+21
-16
lines changed

spec/fixtures/ifconfig_mac

+21-16
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
22
options=1203<RXCSUM,TXCSUM,TXSTATUS,SW_TIMESTAMP>
3-
inet 127.0.0.1 netmask 0xff000000
4-
inet6 ::1 prefixlen 128
5-
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
3+
inet 127.0.0.1 netmask 0xff000000
4+
inet6 ::1 prefixlen 128
5+
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
66
nd6 options=201<PERFORMNUD,DAD>
77
gif0: flags=8010<POINTOPOINT,MULTICAST> mtu 1280
88
stf0: flags=0<> mtu 1280
99
en0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
1010
options=400<CHANNEL_IO>
11-
ether 64:5a:ed:ea:5c:81
11+
ether 64:5a:ed:ea:5c:81
1212
inet 192.168.143.212 netmask 0xffffff00 broadcast 192.168.143.255
1313
media: autoselect
1414
status: active
@@ -23,17 +23,17 @@ en0.1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
2323
nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
2424
en1: flags=8963<UP,BROADCAST,SMART,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1500
2525
options=460<TSO4,TSO6,CHANNEL_IO>
26-
ether 82:17:0e:93:9d:00
26+
ether 82:17:0e:93:9d:00
2727
media: autoselect <full-duplex>
2828
status: inactive
2929
en2: flags=8963<UP,BROADCAST,SMART,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1500
3030
options=460<TSO4,TSO6,CHANNEL_IO>
31-
ether 82:17:0e:93:9d:01
31+
ether 82:17:0e:93:9d:01
3232
media: autoselect <full-duplex>
3333
status: inactive
3434
bridge0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
3535
options=63<RXCSUM,TXCSUM,TSO4,TSO6>
36-
ether 82:17:0e:93:9d:00
36+
ether 82:17:0e:93:9d:00
3737
Configuration:
3838
id 0:0:0:0:0:0 priority 0 hellotime 0 fwddelay 0
3939
maxage 0 holdcnt 0 proto stp maxaddr 100 timeout 1200
@@ -47,33 +47,39 @@ bridge0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
4747
status: inactive
4848
p2p0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 2304
4949
options=400<CHANNEL_IO>
50-
ether 06:5a:ed:ea:5c:81
50+
ether 06:5a:ed:ea:5c:81
5151
media: autoselect
5252
status: inactive
5353
awdl0: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1484
5454
options=400<CHANNEL_IO>
55-
ether 2e:ba:e4:83:4b:b7
56-
inet6 fe80::2cba:e4ff:fe83:4bb7%awdl0 prefixlen 64 scopeid 0x9
55+
ether 2e:ba:e4:83:4b:b7
56+
inet6 fe80::2cba:e4ff:fe83:4bb7%awdl0 prefixlen 64 scopeid 0x9
5757
nd6 options=201<PERFORMNUD,DAD>
5858
media: autoselect
5959
status: active
6060
llw0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
6161
options=400<CHANNEL_IO>
62-
ether 2e:ba:e4:83:4b:b7
63-
inet6 fe80::2cba:e4ff:fe83:4bb7%llw0 prefixlen 64 scopeid 0xa
62+
ether 2e:ba:e4:83:4b:b7
63+
inet6 fe80::2cba:e4ff:fe83:4bb7%llw0 prefixlen 64 scopeid 0xa
6464
nd6 options=201<PERFORMNUD,DAD>
6565
media: aumm,l.j hn toselect
6666
status: active
6767
utun0: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1380
68-
inet6 fe80::ba29:a797:6aa:9eb%utun0 prefixlen 64 scopeid 0xb
68+
inet6 fe80::ba29:a797:6aa:9eb%utun0 prefixlen 64 scopeid 0xb
6969
nd6 options=201<PERFORMNUD,DAD>
7070
utun1: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 2000
71-
inet6 fe80::64c6:1885:bec0:c316%utun1 prefixlen 64 scopeid 0xc
71+
inet6 fe80::64c6:1885:bec0:c316%utun1 prefixlen 64 scopeid 0xc
7272
nd6 options=201<PERFORMNUD,DAD>
7373
utun2: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
74-
inet 10.16.132.213 --> 10.16.132.213 netmask 0xfffffe00
74+
inet 10.16.132.213 --> 10.16.132.213 netmask 0xfffffe00
7575
utun3: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
7676
inet6 2001:db8:cafe::132:213 --> 2001:db8:cafe::132:213 prefixlen 128
77+
utun4: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1380
78+
tunnel inet 192.0.2.1 --> 192.0.2.2
79+
inet 192.0.2.100 --> 192.0.2.101 netmask 0xffffffff
80+
utun5: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1380
81+
tunnel inet 192.0.2.1 --> 192.0.2.2
82+
inet6 2001:db8::1 --> 2001:db8::2 prefixlen 128
7783
ib0: flags=4099<UP,BROADCAST,MULTICAST> mtu 4092
7884
infiniband 80:00:02:08:FA:81:00:00:00:00:00:00:00:00:00:00:00:00:00:00 txqueuelen 256 (InfiniBand)
7985
RX packets 0 bytes 0 (0.0 B)
@@ -87,4 +93,3 @@ ib1: flags=4099<UP,BROADCAST,MULTICAST> mtu 4092
8793
RX errors 0 dropped 0 overruns 0 frame 0
8894
TX packets 0 bytes 0 (0.0 B)
8995
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
90-

0 commit comments

Comments
 (0)