]> git.neil.brown.name Git - history.git/commitdiff
[IPSEC]: Fix UDP decap code.
authorBert Hubert <ahu@ds9a.nl>
Sat, 31 Jul 2004 16:41:30 +0000 (09:41 -0700)
committerDavid S. Miller <davem@nuts.davemloft.net>
Sat, 31 Jul 2004 16:41:30 +0000 (09:41 -0700)
The missing break causes the packet to be tested against
both encapsulation types, one will always fail.

Signed-off-by: bert hubert <ahu@ds9a.nl>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@redhat.com>
net/ipv4/udp.c

index 8ecf48adb4225e670b66dbf316af1378c46b1152..944830a72059c581f12e85ce5def640f4cbb381f 100644 (file)
@@ -930,7 +930,7 @@ static int udp_encap_rcv(struct sock * sk, struct sk_buff *skb)
                } else
                        /* Must be an IKE packet.. pass it through */
                        return 1;
-
+               break;
        case UDP_ENCAP_ESPINUDP_NON_IKE:
                /* Check if this is a keepalive packet.  If so, eat it. */
                if (len == 1 && udpdata[0] == 0xff) {
@@ -943,6 +943,7 @@ static int udp_encap_rcv(struct sock * sk, struct sk_buff *skb)
                } else
                        /* Must be an IKE packet.. pass it through */
                        return 1;
+               break;
        }
 
        /* At this point we are sure that this is an ESPinUDP packet,