summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authoruwe <uwe@NetBSD.org>2019-10-06 02:30:58 +0000
committeruwe <uwe@NetBSD.org>2019-10-06 02:30:58 +0000
commit779c10d352da9d3f186283d97facbb30ec794a6d (patch)
treeb9fcde6de04d6701a64b8f471441d887a7e35281 /sys
parent1069de1e2d10bbbdef561c706e3cef3d61bb581d (diff)
icmp6_notify_error - fix ctlfunc typedef to match pr_ctlinput,
drop the cast that is no longer necessary.
Diffstat (limited to 'sys')
-rw-r--r--sys/netinet6/icmp6.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/sys/netinet6/icmp6.c b/sys/netinet6/icmp6.c
index cc98df61a9f..b5ed06ad44f 100644
--- a/sys/netinet6/icmp6.c
+++ b/sys/netinet6/icmp6.c
@@ -1,4 +1,4 @@
-/* $NetBSD: icmp6.c,v 1.242 2018/12/22 14:07:54 maxv Exp $ */
+/* $NetBSD: icmp6.c,v 1.243 2019/10/06 02:30:58 uwe Exp $ */
/* $KAME: icmp6.c,v 1.217 2001/06/20 15:03:29 jinmei Exp $ */
/*
@@ -62,7 +62,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: icmp6.c,v 1.242 2018/12/22 14:07:54 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: icmp6.c,v 1.243 2019/10/06 02:30:58 uwe Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -950,7 +950,7 @@ icmp6_notify_error(struct mbuf *m, int off, int icmp6len, int code)
/* Detect the upper level protocol */
{
- void (*ctlfunc)(int, struct sockaddr *, void *);
+ void *(*ctlfunc)(int, const struct sockaddr *, void *);
u_int8_t nxt = eip6->ip6_nxt;
int eoff = off + sizeof(struct icmp6_hdr) +
sizeof(struct ip6_hdr);
@@ -1077,8 +1077,7 @@ icmp6_notify_error(struct mbuf *m, int off, int icmp6len, int code)
ip6cp.ip6c_cmdarg = (void *)&notifymtu;
}
- ctlfunc = (void (*)(int, struct sockaddr *, void *))
- (inet6sw[ip6_protox[nxt]].pr_ctlinput);
+ ctlfunc = inet6sw[ip6_protox[nxt]].pr_ctlinput;
if (ctlfunc) {
(void)(*ctlfunc)(code, sin6tosa(&icmp6dst), &ip6cp);
}