From: Mattias Nissler Date: Sun, 9 Mar 2008 21:39:32 +0000 (+0100) Subject: rt2x00: Use the correct size when copying the control info in txdone X-Git-Tag: v2.6.26-rc1~1138^2~442 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=95db4d4d5f00cc9b2aa703a05a70902776d8c2f2;p=linux-2.6 rt2x00: Use the correct size when copying the control info in txdone The sizeof() operator was incorrectly applied to the pointer, not the struct. Signed-off-by: Mattias Nissler Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/rt2x00/rt2x00dev.c b/drivers/net/wireless/rt2x00/rt2x00dev.c index b3a639aa05..141b9b8a19 100644 --- a/drivers/net/wireless/rt2x00/rt2x00dev.c +++ b/drivers/net/wireless/rt2x00/rt2x00dev.c @@ -521,7 +521,7 @@ void rt2x00lib_txdone(struct queue_entry *entry, tx_status.ack_signal = 0; tx_status.excessive_retries = (txdesc->status == TX_FAIL_RETRY); tx_status.retry_count = txdesc->retry; - memcpy(&tx_status.control, txdesc->control, sizeof(txdesc->control)); + memcpy(&tx_status.control, txdesc->control, sizeof(*txdesc->control)); if (!(tx_status.control.flags & IEEE80211_TXCTL_NO_ACK)) { if (success)