lkml.org 
[lkml]   [2006]   [Jun]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [Patch] Off by one in drivers/block/floppy.c
On Tue, 27 Jun 2006 23:57:49 +0200, Eric Sesterhenn <snakebyte@gmx.de> wrote:

> +++ linux-2.6.17-git11/drivers/block/floppy.c 2006-06-27 23:49:40.000000000 +0200
> @@ -684,7 +684,7 @@ static void __reschedule_timeout(int dri
> if (drive == current_reqD)
> drive = current_drive;
> del_timer(&fd_timeout);
> - if (drive < 0 || drive > N_DRIVE) {
> + if (drive < 0 || drive > N_DRIVE-1) {
> fd_timeout.expires = jiffies + 20UL * HZ;

Looks ok, although the idiom is "drive >= N_DRIVE".

-- Pete
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-06-30 09:40    [W:0.044 / U:0.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site