[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20081005163604.3799.54969.stgit@localhost.localdomain>
Date: Sun, 05 Oct 2008 17:36:07 +0100
From: Alan Cox <alan@...hat.com>
To: linux-kernel@...r.kernel.org
Subject: [PATCH 04/19] ib700wdt: Fix off by one
This driver can end up accessing one byte out. Found by Zvonimir Rakamaric
Signed-off-by: Alan Cox <alan@...hat.com>
Fixes bug #11399
---
drivers/watchdog/ib700wdt.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/watchdog/ib700wdt.c b/drivers/watchdog/ib700wdt.c
index 05a2810..d48a704 100644
--- a/drivers/watchdog/ib700wdt.c
+++ b/drivers/watchdog/ib700wdt.c
@@ -150,7 +150,7 @@ static int ibwdt_set_heartbeat(int t)
{
int i;
- if ((t < 0) || (t > 30))
+ if ((t < 0) || (t >= 30))
return -EINVAL;
for (i = 0x0F; i > -1; i--)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists