From: Eric Sesterhenn / Snakebyte <snakebyte@gmx.de>
To: linux-kernel@vger.kernel.org
Cc: zaitcev@redhat.com
Subject: [Patch] Off by one in floppy.c
Date: Tue, 22 May 2007 00:57:56 +0200 [thread overview]
Message-ID: <20070521225755.GC16194@alice> (raw)
hi,
another coverity patch i forgot to resend,
original thread here
http://marc.info/?l=linux-kernel&m=115144559823592&w=2
In case drive == N_DRIVE, we get one past the drive_params array.
Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
--- linux-2.6/drivers/block/floppy.c.orig 2007-05-22 00:54:03.000000000 +0200
+++ linux-2.6/drivers/block/floppy.c 2007-05-22 00:54:18.000000000 +0200
@@ -670,7 +670,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) {
fd_timeout.expires = jiffies + 20UL * HZ;
drive = 0;
} else
next reply other threads:[~2007-05-21 22:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-21 22:57 Eric Sesterhenn / Snakebyte [this message]
2007-05-22 1:07 ` [Patch] Off by one in floppy.c Pete Zaitcev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070521225755.GC16194@alice \
--to=snakebyte@gmx.de \
--cc=linux-kernel@vger.kernel.org \
--cc=zaitcev@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox