linux/block/partitions
Antti P Miettinen 49204c116a block/partitions/efi.c: fix bound check
Use ARRAY_SIZE instead of sizeof to get proper max for label length.

Since this is just a read out of bounds it's not that bad, but the
problem becomes user-visible eg if one tries to use DEBUG_PAGEALLOC and
DEBUG_RODATA, at least with some enhancements from Hiroshi.  Of course
the destination array can contain garbage when we read beyond the end of
source array so that would be another user-visible problem.

Signed-off-by: Antti P Miettinen <amiettinen@nvidia.com>
Reviewed-by: Hiroshi Doyu <hdoyu@nvidia.com>
Tested-by: Hiroshi Doyu <hdoyu@nvidia.com>
Cc: Will Drewry <wad@chromium.org>
Cc: Matt Fleming <matt.fleming@intel.com>
Acked-by: Davidlohr Bueso <davidlohr@hp.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-11-21 16:42:27 -08:00
..
acorn.c
acorn.h
aix.c
aix.h
amiga.c
amiga.h
atari.c
atari.h
check.c
check.h
cmdline.c block: change config option name for cmdline partition parsing 2013-09-30 14:31:02 -07:00
cmdline.h
efi.c block/partitions/efi.c: fix bound check 2013-11-21 16:42:27 -08:00
efi.h
ibm.c
ibm.h
karma.c
karma.h
Kconfig block: change config option name for cmdline partition parsing 2013-09-30 14:31:02 -07:00
ldm.c
ldm.h
mac.c
mac.h
Makefile
msdos.c
msdos.h
osf.c
osf.h
sgi.c
sgi.h
sun.c
sun.h
sysv68.c
sysv68.h
ultrix.c
ultrix.h