[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <48622822.3000300@gmail.com>
Date: Wed, 25 Jun 2008 13:12:34 +0200
From: Jiri Slaby <jirislaby@...il.com>
To: Pavel Machek <pavel@...e.cz>
CC: kernel list <linux-kernel@...r.kernel.org>,
linux-wireless@...r.kernel.org, ath5k-devel@...ts.ath5k.org,
linville@...driver.com
Subject: Re: Small cleanups
>> - if ((ai->APList == NULL) &&
>> - (ai->APList = kmalloc(sizeof(APListRid), GFP_KERNEL)) == NULL)
>> + if (!ai->APList)
>> + ai->APList = kmalloc(sizeof(APListRid), GFP_KERNEL);
>> + if (!ai->APList)
>> return -ENOMEM;
>> - if ((ai->SSID == NULL) &&
>> - (ai->SSID = kmalloc(sizeof(SsidRid), GFP_KERNEL)) == NULL)
>> + if (!ai->SSID)
>> + ai->SSID = kmalloc(sizeof(SsidRid), GFP_KERNEL);
>> + if (!ai->SSID)
>> return -ENOMEM;
>
> Would you mind sending another patch which would fix the potential leak?
Sorry, ignore this.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists