]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
mac80211: fix a buffer overrun in station debug code
authorJianjun Kong <jianjun@zeuux.org>
Tue, 11 Nov 2008 05:37:39 +0000 (21:37 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 17 Feb 2009 17:46:29 +0000 (09:46 -0800)
commit 013cd397532e5803a1625954a884d021653da720 upstream.

net/mac80211/debugfs_sta.c
The trailing zero was written to state[4], it's out of bounds.

Signed-off-by: Jianjun Kong <jianjun@zeuux.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/mac80211/debugfs_sta.c

index 79a062782d52e2da757532901a29017e9f420d4e..27bd353919493c868776aaa0f9ba2f2327d69234 100644 (file)
@@ -200,7 +200,7 @@ static ssize_t sta_agg_status_write(struct file *file,
                /* toggle Rx aggregation command */
                tid_num = tid_num - 100;
                if (tid_static_rx[tid_num] == 1) {
-                       strcpy(state, "off ");
+                       strcpy(state, "off");
                        ieee80211_sta_stop_rx_ba_session(dev, da, tid_num, 0,
                                        WLAN_REASON_QSTA_REQUIRE_SETUP);
                        sta->ampdu_mlme.tid_state_rx[tid_num] |=