diff options
author | roel kluin <roel.kluin@gmail.com> | 2009-08-07 03:24:27 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-08-09 21:45:48 -0700 |
commit | 5e33b719c8fcccfedc1d25167826a0f93fe6c5a1 (patch) | |
tree | 17fe28222553c42ea7b5627e0aaf9749634b83ec /drivers | |
parent | 418372b0ab7a3bbcc59d71e8e4d322ef18263dab (diff) |
pcnet32: Read buffer overflow
An `options[cards_found]' that equals `sizeof(options_mapping)' is already beyond
the array.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/pcnet32.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/pcnet32.c b/drivers/net/pcnet32.c index a646a445fda..23e1a0750fe 100644 --- a/drivers/net/pcnet32.c +++ b/drivers/net/pcnet32.c @@ -1839,7 +1839,7 @@ pcnet32_probe1(unsigned long ioaddr, int shared, struct pci_dev *pdev) lp->chip_version = chip_version; lp->msg_enable = pcnet32_debug; if ((cards_found >= MAX_UNITS) - || (options[cards_found] > sizeof(options_mapping))) + || (options[cards_found] >= sizeof(options_mapping))) lp->options = PCNET32_PORT_ASEL; else lp->options = options_mapping[options[cards_found]]; |