From: Dmitry Torokhov <dtor@insightbb.com>
To: Florin Malita <fmalita@gmail.com>
Cc: linux-kernel@vger.kernel.org, akpm@osdl.org
Subject: Re: [PATCH] atkbd.c: overrun in atkbd_set_repeat_rate()
Date: Sun, 13 Aug 2006 19:50:28 -0400 [thread overview]
Message-ID: <200608131950.28720.dtor@insightbb.com> (raw)
In-Reply-To: <44DF953B.6010707@gmail.com>
On Sunday 13 August 2006 17:10, Florin Malita wrote:
> This was introduced in commit 3d0f0fa0cb554541e10cb8cb84104e4b10828468:
> bounds checking is performed against period[32] while indexing delay[4].
>
> Spotted by Coverity, CID 1376.
>
Will apply, thank you.
> Signed-off-by: Florin Malita <fmalita@gmail.com>
> ---
>
> diff --git a/drivers/input/keyboard/atkbd.c b/drivers/input/keyboard/atkbd.c
> index 6bfa0cf..a86afd0 100644
> --- a/drivers/input/keyboard/atkbd.c
> +++ b/drivers/input/keyboard/atkbd.c
> @@ -498,7 +498,7 @@ static int atkbd_set_repeat_rate(struct
> i++;
> dev->rep[REP_PERIOD] = period[i];
>
> - while (j < ARRAY_SIZE(period) - 1 && delay[j] < dev->rep[REP_DELAY])
> + while (j < ARRAY_SIZE(delay) - 1 && delay[j] < dev->rep[REP_DELAY])
> j++;
> dev->rep[REP_DELAY] = delay[j];
>
>
>
--
Dmitry
prev parent reply other threads:[~2006-08-13 23:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-13 21:10 [PATCH] atkbd.c: overrun in atkbd_set_repeat_rate() Florin Malita
2006-08-13 23:50 ` Dmitry Torokhov [this message]
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=200608131950.28720.dtor@insightbb.com \
--to=dtor@insightbb.com \
--cc=akpm@osdl.org \
--cc=fmalita@gmail.com \
--cc=linux-kernel@vger.kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.