2009-04-07 19:41:19

by Philip Rakity

[permalink] [raw]
Subject: [PATCH] libertas: don't leak skb on receive error



Don't lead memory when receive errors
Signed-off-by: Philip Rakity <[email protected]>

--- linux-2.6.29/drivers/net/wireless/libertas/rx.c.old 2009-04-01 13:19:26.000000000 -0700
+++ linux-2.6.29/drivers/net/wireless/libertas/rx.c 2009-04-01 13:19:57.000000000 -0700
@@ -170,6 +170,7 @@
lbs_deb_rx("rx err: frame received with bad length\n");
priv->stats.rx_length_errors++;
ret = 0;
+ dev_kfree_skb(skb);
goto done;
}

@@ -181,6 +182,7 @@
lbs_pr_alert("rxpd not ok\n");
priv->stats.rx_errors++;
ret = 0;
+ dev_kfree_skb(skb);
goto done;






2009-04-08 07:26:15

by Holger Schurig

[permalink] [raw]
Subject: Re: [PATCH] libertas: don't leak skb on receive error

> Don't lead memory when receive errors
> Signed-off-by: Philip Rakity <[email protected]>

Looks fine from my site (the libertas-if_cs-guy).

2009-04-21 17:40:11

by Chris Wright

[permalink] [raw]
Subject: Re: [stable] [PATCH] libertas: don't leak skb on receive error

* Dan Williams ([email protected]) wrote:
> On Tue, 2009-04-07 at 12:41 -0700, Philip Rakity wrote:
> >
> > Don't lead memory when receive errors
> > Signed-off-by: Philip Rakity <[email protected]>
>
> Acked-by: Dan Williams <[email protected]>

Doesn't look like this is upstream yet. Please send to
[email protected] when it is.

thanks,
-chris

2009-04-08 14:23:15

by Dan Williams

[permalink] [raw]
Subject: Re: [PATCH] libertas: don't leak skb on receive error

On Tue, 2009-04-07 at 12:41 -0700, Philip Rakity wrote:
>
> Don't lead memory when receive errors
> Signed-off-by: Philip Rakity <[email protected]>

Acked-by: Dan Williams <[email protected]>

> --- linux-2.6.29/drivers/net/wireless/libertas/rx.c.old 2009-04-01 13:19:26.000000000 -0700
> +++ linux-2.6.29/drivers/net/wireless/libertas/rx.c 2009-04-01 13:19:57.000000000 -0700
> @@ -170,6 +170,7 @@
> lbs_deb_rx("rx err: frame received with bad length\n");
> priv->stats.rx_length_errors++;
> ret = 0;
> + dev_kfree_skb(skb);
> goto done;
> }
>
> @@ -181,6 +182,7 @@
> lbs_pr_alert("rxpd not ok\n");
> priv->stats.rx_errors++;
> ret = 0;
> + dev_kfree_skb(skb);
> goto done;
>
>
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html