diff options
author | 2015-06-07 12:02:28 +0000 | |
---|---|---|
committer | 2015-06-07 12:02:28 +0000 | |
commit | ba4138390b9fd1585b0009db6ac54b8875efca33 (patch) | |
tree | 8ed1945da6446c80011c2b98506c873a9d57fff9 /sys/netinet/tcp_usrreq.c | |
parent | mark the usb hci driver pci glue code as only needed by the pci attachment, (diff) | |
download | wireguard-openbsd-ba4138390b9fd1585b0009db6ac54b8875efca33.tar.xz wireguard-openbsd-ba4138390b9fd1585b0009db6ac54b8875efca33.zip |
Introduce unhandled_af() for cases where code conditionally does
something based on an address family and later assumes one of the paths
was taken. This was initially just calls to panic until guenther
suggested a function to reduce the amount of strings needed.
This reduces the amount of noise with static analysers and acts
as a sanity check.
ok guenther@ bluhm@
Diffstat (limited to 'sys/netinet/tcp_usrreq.c')
-rw-r--r-- | sys/netinet/tcp_usrreq.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/netinet/tcp_usrreq.c b/sys/netinet/tcp_usrreq.c index 52c81ee38de..8418b99a3df 100644 --- a/sys/netinet/tcp_usrreq.c +++ b/sys/netinet/tcp_usrreq.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tcp_usrreq.c,v 1.124 2015/06/07 01:25:27 krw Exp $ */ +/* $OpenBSD: tcp_usrreq.c,v 1.125 2015/06/07 12:02:28 jsg Exp $ */ /* $NetBSD: tcp_usrreq.c,v 1.20 1996/02/13 23:44:16 christos Exp $ */ /* @@ -824,6 +824,8 @@ tcp_ident(void *oldp, size_t *oldlenp, void *newp, size_t newlen, int dodrop) inp = in_pcbhashlookup(&tcbtable, fin->sin_addr, fin->sin_port, lin->sin_addr, lin->sin_port, tir.rdomain); break; + default: + unhandled_af(tir.faddr.ss_family); } if (dodrop) { |