Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 322001
b: refs/heads/master
c: 60f53cf
h: refs/heads/master
i:
  321999: 61f00ac
v: v3
  • Loading branch information
Alexey Khoroshilov authored and John W. Linville committed Aug 10, 2012
1 parent 5f5175c commit 2453ec5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f41a9b3b15e0f74656f69e6da403d870c53ea4e6
refs/heads/master: 60f53cf99060472973f16452116d9c467f8b08c6
6 changes: 4 additions & 2 deletions trunk/drivers/net/wireless/rndis_wlan.c
Original file line number Diff line number Diff line change
Expand Up @@ -1803,6 +1803,7 @@ static struct ndis_80211_pmkid *update_pmkid(struct usbnet *usbdev,
struct cfg80211_pmksa *pmksa,
int max_pmkids)
{
struct ndis_80211_pmkid *new_pmkids;
int i, err, newlen;
unsigned int count;

Expand Down Expand Up @@ -1833,11 +1834,12 @@ static struct ndis_80211_pmkid *update_pmkid(struct usbnet *usbdev,
/* add new pmkid */
newlen = sizeof(*pmkids) + (count + 1) * sizeof(pmkids->bssid_info[0]);

pmkids = krealloc(pmkids, newlen, GFP_KERNEL);
if (!pmkids) {
new_pmkids = krealloc(pmkids, newlen, GFP_KERNEL);
if (!new_pmkids) {
err = -ENOMEM;
goto error;
}
pmkids = new_pmkids;

pmkids->length = cpu_to_le32(newlen);
pmkids->bssid_info_count = cpu_to_le32(count + 1);
Expand Down

0 comments on commit 2453ec5

Please sign in to comment.