mausezahn: Add error handling for mismatched address families
commitbf0df3ec1875df4b167aedd0fff25e7e56408b6b
authorMandar Gokhale <mandarg@mandarg.com>
Thu, 8 Dec 2016 04:20:20 +0000 (7 23:20 -0500)
committerTobias Klauser <tklauser@distanz.ch>
Thu, 8 Dec 2016 08:28:30 +0000 (8 09:28 +0100)
tree7cfc7d52cedb96a9d87c9cea385c0c7ba8b358e9
parent7b71c2c487ec2eed2d8dcd22f621f6c913621312
mausezahn: Add error handling for mismatched address families

Currently, mausezahn fails silently if, say the user has specified
IPv6 addresses using `-A` and `-B` but has forgotten the -6
option. Add error handling for this and the (probably uncommon)
reverse case, i.e. v4 src/dst specified, but used with the -6 option.

Signed-off-by: Mandar Gokhale <mandarg@mandarg.com>
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
staging/mausezahn.c