diff options
author | John W. Linville <linville@tuxdriver.com> | 2008-05-02 09:56:34 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-05-12 21:18:05 -0400 |
commit | d5251aea1539ec89dd567e75169c568b5243b6fa (patch) | |
tree | c232805f91f6ac46d30ce72c1092897ca2b921de /drivers | |
parent | bb55bdd512905f35f9d7dfe65d1f16014e1f9b2f (diff) |
wavelan: avoid index past end of array if DEBUG_SHOW_UNUSED is defined
Reported by Daniel Marjamäki <danielm77@spray.se> here:
http://bugzilla.kernel.org/show_bug.cgi?id=10588
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/wavelan.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/wavelan_cs.c | 6 |
2 files changed, 4 insertions, 6 deletions
diff --git a/drivers/net/wireless/wavelan.c b/drivers/net/wireless/wavelan.c index 03384a43186b..49ae97003952 100644 --- a/drivers/net/wireless/wavelan.c +++ b/drivers/net/wireless/wavelan.c | |||
@@ -908,9 +908,9 @@ static void wv_psa_show(psa_t * p) | |||
908 | p->psa_call_code[3], p->psa_call_code[4], p->psa_call_code[5], | 908 | p->psa_call_code[3], p->psa_call_code[4], p->psa_call_code[5], |
909 | p->psa_call_code[6], p->psa_call_code[7]); | 909 | p->psa_call_code[6], p->psa_call_code[7]); |
910 | #ifdef DEBUG_SHOW_UNUSED | 910 | #ifdef DEBUG_SHOW_UNUSED |
911 | printk(KERN_DEBUG "psa_reserved[]: %02X:%02X:%02X:%02X\n", | 911 | printk(KERN_DEBUG "psa_reserved[]: %02X:%02X\n", |
912 | p->psa_reserved[0], | 912 | p->psa_reserved[0], |
913 | p->psa_reserved[1], p->psa_reserved[2], p->psa_reserved[3]); | 913 | p->psa_reserved[1]); |
914 | #endif /* DEBUG_SHOW_UNUSED */ | 914 | #endif /* DEBUG_SHOW_UNUSED */ |
915 | printk(KERN_DEBUG "psa_conf_status: %d, ", p->psa_conf_status); | 915 | printk(KERN_DEBUG "psa_conf_status: %d, ", p->psa_conf_status); |
916 | printk("psa_crc: 0x%02x%02x, ", p->psa_crc[0], p->psa_crc[1]); | 916 | printk("psa_crc: 0x%02x%02x, ", p->psa_crc[0], p->psa_crc[1]); |
diff --git a/drivers/net/wireless/wavelan_cs.c b/drivers/net/wireless/wavelan_cs.c index baf74015751c..b584c0ecc62d 100644 --- a/drivers/net/wireless/wavelan_cs.c +++ b/drivers/net/wireless/wavelan_cs.c | |||
@@ -1074,11 +1074,9 @@ wv_psa_show(psa_t * p) | |||
1074 | p->psa_call_code[6], | 1074 | p->psa_call_code[6], |
1075 | p->psa_call_code[7]); | 1075 | p->psa_call_code[7]); |
1076 | #ifdef DEBUG_SHOW_UNUSED | 1076 | #ifdef DEBUG_SHOW_UNUSED |
1077 | printk(KERN_DEBUG "psa_reserved[]: %02X:%02X:%02X:%02X\n", | 1077 | printk(KERN_DEBUG "psa_reserved[]: %02X:%02X\n", |
1078 | p->psa_reserved[0], | 1078 | p->psa_reserved[0], |
1079 | p->psa_reserved[1], | 1079 | p->psa_reserved[1]); |
1080 | p->psa_reserved[2], | ||
1081 | p->psa_reserved[3]); | ||
1082 | #endif /* DEBUG_SHOW_UNUSED */ | 1080 | #endif /* DEBUG_SHOW_UNUSED */ |
1083 | printk(KERN_DEBUG "psa_conf_status: %d, ", p->psa_conf_status); | 1081 | printk(KERN_DEBUG "psa_conf_status: %d, ", p->psa_conf_status); |
1084 | printk("psa_crc: 0x%02x%02x, ", p->psa_crc[0], p->psa_crc[1]); | 1082 | printk("psa_crc: 0x%02x%02x, ", p->psa_crc[0], p->psa_crc[1]); |