Remove dead code.

This commit is contained in:
maxv 2018-04-23 09:58:35 +00:00
parent 6cf02a93b7
commit 832b034324
1 changed files with 2 additions and 23 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: traceroute6.c,v 1.46 2018/04/23 09:47:03 maxv Exp $ */ /* $NetBSD: traceroute6.c,v 1.47 2018/04/23 09:58:35 maxv Exp $ */
/* $KAME: traceroute6.c,v 1.67 2004/01/25 03:24:39 itojun Exp $ */ /* $KAME: traceroute6.c,v 1.67 2004/01/25 03:24:39 itojun Exp $ */
/* /*
@ -75,7 +75,7 @@ static char sccsid[] = "@(#)traceroute.c 8.1 (Berkeley) 6/6/93";
#else #else
#include <sys/cdefs.h> #include <sys/cdefs.h>
#ifndef lint #ifndef lint
__RCSID("$NetBSD: traceroute6.c,v 1.46 2018/04/23 09:47:03 maxv Exp $"); __RCSID("$NetBSD: traceroute6.c,v 1.47 2018/04/23 09:58:35 maxv Exp $");
#endif #endif
#endif #endif
@ -319,9 +319,6 @@ static int setpolicy(int so, const char *policy);
#endif #endif
static void send_probe(int, u_long); static void send_probe(int, u_long);
static struct udphdr *get_udphdr(struct ip6_hdr *, u_char *); static struct udphdr *get_udphdr(struct ip6_hdr *, u_char *);
#if 0
static int get_hoplim(struct msghdr *);
#endif
static double deltaT(struct timeval *, struct timeval *); static double deltaT(struct timeval *, struct timeval *);
static const char *pr_type(int); static const char *pr_type(int);
static int packet_ok(struct msghdr *, ssize_t, int); static int packet_ok(struct msghdr *, ssize_t, int);
@ -915,24 +912,6 @@ send_probe(int seq, u_long hops)
} }
} }
#if 0
static int
get_hoplim(struct msghdr *mhdr)
{
struct cmsghdr *cm;
for (cm = (struct cmsghdr *)CMSG_FIRSTHDR(mhdr); cm;
cm = (struct cmsghdr *)CMSG_NXTHDR(mhdr, cm)) {
if (cm->cmsg_level == IPPROTO_IPV6 &&
cm->cmsg_type == IPV6_HOPLIMIT &&
cm->cmsg_len == CMSG_LEN(sizeof(int)))
return *(int *)CMSG_DATA(cm);
}
return -1;
}
#endif
static double static double
deltaT(struct timeval *t1p, struct timeval *t2p) deltaT(struct timeval *t1p, struct timeval *t2p)
{ {