projects
/
powerpc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge master.kernel.org:/pub/scm/linux/kernel/git/davej/agpgart
[powerpc.git]
/
net
/
ipv4
/
tunnel4.c
diff --git
a/net/ipv4/tunnel4.c
b/net/ipv4/tunnel4.c
index
0d7d386
..
8d30c48
100644
(file)
--- a/
net/ipv4/tunnel4.c
+++ b/
net/ipv4/tunnel4.c
@@
-8,6
+8,8
@@
#include <linux/mutex.h>
#include <linux/netdevice.h>
#include <linux/skbuff.h>
#include <linux/mutex.h>
#include <linux/netdevice.h>
#include <linux/skbuff.h>
+#include <net/icmp.h>
+#include <net/ip.h>
#include <net/protocol.h>
#include <net/xfrm.h>
#include <net/protocol.h>
#include <net/xfrm.h>
@@
-70,10
+72,16
@@
static int tunnel4_rcv(struct sk_buff *skb)
{
struct xfrm_tunnel *handler;
{
struct xfrm_tunnel *handler;
+ if (!pskb_may_pull(skb, sizeof(struct iphdr)))
+ goto drop;
+
for (handler = tunnel4_handlers; handler; handler = handler->next)
if (!handler->handler(skb))
return 0;
for (handler = tunnel4_handlers; handler; handler = handler->next)
if (!handler->handler(skb))
return 0;
+ icmp_send(skb, ICMP_DEST_UNREACH, ICMP_PORT_UNREACH, 0);
+
+drop:
kfree_skb(skb);
return 0;
}
kfree_skb(skb);
return 0;
}