Skip to contentSkip to conversation

at1700: Read buffer overflow

PATCH Applied Roel Kluin 2 participants 2 messages Jul 25, 2009 – Jul 27, 2009

Subsystems (2)
lore
Share & tools
lore

Roel Kluin

author
#0 lore raw

PATCH 1/1 at1700: Read buffer overflow

loop bound looks to be wrong, for an array of length 8

---
Or is a value is missing? (others contrastingly end with `, 0')

drivers/net/at1700.c +1 -1
index 18b566a..cf30e27 100644
@@ -318,7 +318,7 @@ static int __init at1700_probe1(struct net_device *dev, int ioaddr)
 				pos3 = mca_read_stored_pos( slot, 3 );
 				pos4 = mca_read_stored_pos( slot, 4 );
 
-				for (l_i = 0; l_i < 0x09; l_i++)
+				for (l_i = 0; l_i < 8; l_i++)
 					if (( pos3 & 0x07) == at1700_ioaddr_pattern[l_i])
 						break;
 				ioaddr = at1700_mca_probe_list[l_i];