Remove unnecessary NULL check
This commit is contained in:
parent
89e11e0339
commit
752d3b8752
@ -1,4 +1,4 @@
|
|||||||
/* $NetBSD: nd6_rtr.c,v 1.134 2017/03/03 06:27:20 msaitoh Exp $ */
|
/* $NetBSD: nd6_rtr.c,v 1.135 2017/03/14 04:21:38 ozaki-r Exp $ */
|
||||||
/* $KAME: nd6_rtr.c,v 1.95 2001/02/07 08:09:47 itojun Exp $ */
|
/* $KAME: nd6_rtr.c,v 1.95 2001/02/07 08:09:47 itojun Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -31,7 +31,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sys/cdefs.h>
|
#include <sys/cdefs.h>
|
||||||
__KERNEL_RCSID(0, "$NetBSD: nd6_rtr.c,v 1.134 2017/03/03 06:27:20 msaitoh Exp $");
|
__KERNEL_RCSID(0, "$NetBSD: nd6_rtr.c,v 1.135 2017/03/14 04:21:38 ozaki-r Exp $");
|
||||||
|
|
||||||
#ifdef _KERNEL_OPT
|
#ifdef _KERNEL_OPT
|
||||||
#include "opt_net_mpsafe.h"
|
#include "opt_net_mpsafe.h"
|
||||||
@ -581,11 +581,6 @@ defrouter_delreq(struct nd_defrouter *dr)
|
|||||||
} def, mask, gw;
|
} def, mask, gw;
|
||||||
int error;
|
int error;
|
||||||
|
|
||||||
#ifdef DIAGNOSTIC
|
|
||||||
if (dr == NULL)
|
|
||||||
panic("dr == NULL in defrouter_delreq");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
memset(&def, 0, sizeof(def));
|
memset(&def, 0, sizeof(def));
|
||||||
memset(&mask, 0, sizeof(mask));
|
memset(&mask, 0, sizeof(mask));
|
||||||
memset(&gw, 0, sizeof(gw)); /* for safety */
|
memset(&gw, 0, sizeof(gw)); /* for safety */
|
||||||
|
Loading…
Reference in New Issue
Block a user