From: Adrian Bunk <bunk@kernel.org>
To: David Howells <dhowells@redhat.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [2.6 patch] fs/afs/vlocation.c: fix off-by-one
Date: Mon, 29 Oct 2007 16:24:47 +0100 [thread overview]
Message-ID: <20071029152447.GP7227@stusta.de> (raw)
In-Reply-To: <3357.1193662826@redhat.com>
On Mon, Oct 29, 2007 at 01:00:26PM +0000, David Howells wrote:
> Adrian Bunk <bunk@kernel.org> wrote:
>
> > This patch fixes an off-by-one error spotted by the Coverity checker.
>
> NAK.
>
> Why do you assume it's a NUL-terminated string? It's not. It's a fixed
> length character array that gets padded out with NULs.
>
> Look 9 lines further down in the file from the change you made. You'll notice
> it is using memcmp() not strcmp().
Check the last line of the patch I sent:
if (vl->vldb.name[namesz] != '\0')
> David
cu
Adrian
--
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed
next prev parent reply other threads:[~2007-10-29 15:24 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-27 14:19 [2.6 patch] fs/afs/vlocation.c: fix off-by-one Adrian Bunk
2007-10-29 13:00 ` David Howells
2007-10-29 15:24 ` Adrian Bunk [this message]
2007-10-29 15:30 ` David Howells
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=20071029152447.GP7227@stusta.de \
--to=bunk@kernel.org \
--cc=dhowells@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox