key_gettunnel() has been unsued with FAST_IPSEC (now IPSEC).

KAME had explicit checks at one point using it, so just hide it behind
#if 0 for now until we are sure if we can completely dump it or not.

MFC after:	1 month
This commit is contained in:
bz 2009-04-27 21:04:16 +00:00
parent 07fcd69a1a
commit a12cc82f1a
2 changed files with 6 additions and 0 deletions

View File

@ -684,6 +684,7 @@ key_allocsp2(u_int32_t spi,
return sp;
}
#if 0
/*
* return a policy that matches this particular inbound packet.
* XXX slow
@ -760,6 +761,7 @@ key_gettunnel(const struct sockaddr *osrc,
sp, sp ? sp->id : 0, sp ? sp->refcnt : 0));
return sp;
}
#endif
/*
* allocating an SA entry for an *OUTBOUND* packet.

View File

@ -53,9 +53,11 @@ extern struct secpolicy *key_allocsp(struct secpolicyindex *, u_int,
extern struct secpolicy *key_allocsp2(u_int32_t spi, union sockaddr_union *dst,
u_int8_t proto, u_int dir, const char*, int);
extern struct secpolicy *key_newsp(const char*, int);
#if 0
extern struct secpolicy *key_gettunnel(const struct sockaddr *,
const struct sockaddr *, const struct sockaddr *,
const struct sockaddr *, const char*, int);
#endif
/* NB: prepend with _ for KAME IPv6 compatbility */
extern void _key_freesp(struct secpolicy **, const char*, int);
@ -65,8 +67,10 @@ extern void _key_freesp(struct secpolicy **, const char*, int);
key_allocsp2(spi, dst, proto, dir, __FILE__, __LINE__)
#define KEY_NEWSP() \
key_newsp(__FILE__, __LINE__)
#if 0
#define KEY_GETTUNNEL(osrc, odst, isrc, idst) \
key_gettunnel(osrc, odst, isrc, idst, __FILE__, __LINE__)
#endif
#define KEY_FREESP(spp) \
_key_freesp(spp, __FILE__, __LINE__)