packetcap / go-pcap

Packet capture library and tools in native go
Apache License 2.0
26 stars 7 forks source link

when checking netmask, use AND and not ADD #51

Closed deitch closed 6 months ago

deitch commented 6 months ago

The original had a typo, using ALUOpAdd for adding the netmask in the BPF operation, when it should have been ALUOpAnd (one letter difference). This made netmasked operations fail. It also therefore carried through to all of the tests.

Fixes #50