Don't sleep when handling ESP over UDP packets.
This commit is contained in:
parent
99c093bad3
commit
52786ce730
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: udp_usrreq.c,v 1.136 2005/04/23 14:05:28 manu Exp $ */
|
||||
/* $NetBSD: udp_usrreq.c,v 1.137 2005/04/25 20:37:06 manu Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
|
||||
|
@ -61,7 +61,7 @@
|
|||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: udp_usrreq.c,v 1.136 2005/04/23 14:05:28 manu Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: udp_usrreq.c,v 1.137 2005/04/25 20:37:06 manu Exp $");
|
||||
|
||||
#include "opt_inet.h"
|
||||
#include "opt_ipsec.h"
|
||||
|
@ -1456,8 +1456,11 @@ udp4_espinudp(m, off, src, so)
|
|||
* to select the right SPD for multiple hosts behind
|
||||
* same NAT
|
||||
*/
|
||||
tag = m_tag_get(PACKET_TAG_IPSEC_NAT_T_PORTS,
|
||||
sizeof(sport) + sizeof(dport), M_WAITOK);
|
||||
if ((tag = m_tag_get(PACKET_TAG_IPSEC_NAT_T_PORTS,
|
||||
sizeof(sport) + sizeof(dport), M_DONTWAIT)) == NULL) {
|
||||
printf("udp4_espinudp: m_tag_get failed\n");
|
||||
return 0;
|
||||
}
|
||||
((u_int16_t *)(tag + 1))[0] = sport;
|
||||
((u_int16_t *)(tag + 1))[1] = dport;
|
||||
m_tag_prepend(n, tag);
|
||||
|
|
Loading…
Reference in New Issue