]> git.baikalelectronics.ru Git - kernel.git/commit
ROMFS: fix length used with romfs_dev_strnlen() function
authorBernd Schmidt <bernds_cb1@t-online.de>
Tue, 6 Oct 2009 08:55:26 +0000 (09:55 +0100)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sun, 11 Oct 2009 18:33:56 +0000 (11:33 -0700)
commit14c9f9838dd1d272a57b7c734435dcff7b8ffd2d
treee73d6e0e852d370effdb9e6fb624e696321683ac
parent7496e1c550975ac6e3ba8ac0db4b347f41224656
ROMFS: fix length used with romfs_dev_strnlen() function

An interestingly corrupted romfs file system exposed a problem with the
romfs_dev_strnlen function: it's passing the wrong value to its helpers.
Rather than limit the string to the length passed in by the callers, it
uses the size of the device as the limit.

Signed-off-by: Bernd Schmidt <bernds_cb1@t-online.de>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/romfs/storage.c