summaryrefslogtreecommitdiff
path: root/drivers/staging/gdm72xx
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2013-07-22 11:00:53 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-07-23 15:08:50 -0700
commitf2a6fed1ceaecf6054627f0ddbd4becf43c997fc (patch)
treed3c8b786a76aa3305ada0efb3b93368eaec688e3 /drivers/staging/gdm72xx
parent3a349cee593a464b25f329a1b76635900187fdb0 (diff)
staging: gdm72xx: potential use after free in send_qos_list()
Sometimes free_qos_entry() sometimes frees its argument. I have moved the dereference of "entry" ahead on line to avoid a use after free. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/gdm72xx')
-rw-r--r--drivers/staging/gdm72xx/gdm_qos.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/gdm72xx/gdm_qos.c b/drivers/staging/gdm72xx/gdm_qos.c
index b795353e8348..cc3692439a5c 100644
--- a/drivers/staging/gdm72xx/gdm_qos.c
+++ b/drivers/staging/gdm72xx/gdm_qos.c
@@ -250,8 +250,8 @@ static void send_qos_list(struct nic *nic, struct list_head *head)
list_for_each_entry_safe(entry, n, head, list) {
list_del(&entry->list);
- free_qos_entry(entry);
gdm_wimax_send_tx(entry->skb, entry->dev);
+ free_qos_entry(entry);
}
}