[PATCH] i2400m/USB: fix kfree(skb)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Saturday 17 January 2009, Roel Kluin wrote:
> Fix kfree(skb)
>
> Signed-off-by: Roel Kluin <roel.kluin@xxxxxxxxx>
> ---
> FYI:
> I noted that in the latter patch, function i2400mu_rx() rx_skb is freed,
> but at label :out still rx_skb is returned

Huh, good catch -- that's embarrassing.

> But this doesn't matter since the return value of this function, only
> called at lines 342 and 404, is checked with:
>
> ret = i2400mu_rx(...);
> if (IS_ERR(ret))
> 	return PTR_ERR(ret);

Well, as the 'out:' path returns rx_skb, in that error path it should
be set to NULL and i2400mu_rxd() should check for that and treat is as
a retryable condition (I don't think it makes much sense to quit because
of that).

I'll rework your patch to add that.

Thank you!

-- 
Inaky


[Index of Archives]     [Linux Kernel]     [Linux Wireless]     [Linux Bluetooth]     [Linux Netdev]     [Linux Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux