]> err.no Git - linux-2.6/blobdiff - net/ipv6/esp6.c
Merge ../linux-2.6
[linux-2.6] / net / ipv6 / esp6.c
index aa7f100dab35e74a828531359458b5ec2eaf29b9..22f04607903759bd59eae8c1d11b49d3c58c1582 100644 (file)
@@ -130,7 +130,7 @@ error:
        return err;
 }
 
-static int esp6_input(struct xfrm_state *x, struct xfrm_decap_state *decap, struct sk_buff *skb)
+static int esp6_input(struct xfrm_state *x, struct sk_buff *skb)
 {
        struct ipv6hdr *iph;
        struct ipv6_esp_hdr *esph;
@@ -305,12 +305,10 @@ static int esp6_init_state(struct xfrm_state *x)
        if (x->encap)
                goto error;
 
-       esp = kmalloc(sizeof(*esp), GFP_KERNEL);
+       esp = kzalloc(sizeof(*esp), GFP_KERNEL);
        if (esp == NULL)
                return -ENOMEM;
 
-       memset(esp, 0, sizeof(*esp));
-
        if (x->aalg) {
                struct xfrm_algo_desc *aalg_desc;