aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAdrian Bunk <bunk@kernel.org>2007-11-05 17:50:57 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-11-05 18:12:32 -0500
commit6551198a201a70cb11e25712b1d0b2a369bb8a4c (patch)
treeb4ca66da0b68b182df8761a058109a14ecefbcaa /fs
parentf11b7ae8d6180bb3c0ad04b38a8ca7e0a26c6605 (diff)
fs/afs/vlocation.c: fix off-by-one
This patch fixes an off-by-one error spotted by the Coverity checker. Signed-off-by: Adrian Bunk <bunk@kernel.org> Acked-by: David Howells <dhowells@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs')
-rw-r--r--fs/afs/vlocation.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/afs/vlocation.c b/fs/afs/vlocation.c
index 7b4bbe48112d..849fc3160cb5 100644
--- a/fs/afs/vlocation.c
+++ b/fs/afs/vlocation.c
@@ -382,7 +382,7 @@ struct afs_vlocation *afs_vlocation_lookup(struct afs_cell *cell,
382 cell->name, key_serial(key), 382 cell->name, key_serial(key),
383 (int) namesz, (int) namesz, name, namesz); 383 (int) namesz, (int) namesz, name, namesz);
384 384
385 if (namesz > sizeof(vl->vldb.name)) { 385 if (namesz >= sizeof(vl->vldb.name)) {
386 _leave(" = -ENAMETOOLONG"); 386 _leave(" = -ENAMETOOLONG");
387 return ERR_PTR(-ENAMETOOLONG); 387 return ERR_PTR(-ENAMETOOLONG);
388 } 388 }