mirror of
https://github.com/torvalds/linux.git
synced 2024-11-29 07:31:29 +00:00
a1aa5390cc
In of_modalias(), we can get passed the str and len parameters which would cause a kernel oops in vsnprintf() since it only allows passing a NULL ptr when the length is also 0. Also, we need to filter out the negative values of the len parameter as these will result in a really huge buffer since snprintf() takes size_t parameter while ours is ssize_t... Found by Linux Verification Center (linuxtesting.org) with the Svace static analysis tool. Signed-off-by: Sergey Shtylyov <s.shtylyov@omp.ru> Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/1d211023-3923-685b-20f0-f3f90ea56e1f@omp.ru Signed-off-by: Rob Herring <robh@kernel.org> |
||
---|---|---|
.. | ||
unittest-data | ||
.kunitconfig | ||
address.c | ||
base.c | ||
cpu.c | ||
device.c | ||
dynamic.c | ||
empty_root.dts | ||
fdt_address.c | ||
fdt.c | ||
irq.c | ||
Kconfig | ||
kexec.c | ||
kobj.c | ||
Makefile | ||
module.c | ||
of_numa.c | ||
of_private.h | ||
of_reserved_mem.c | ||
of_test.c | ||
overlay.c | ||
pdt.c | ||
platform.c | ||
property.c | ||
resolver.c | ||
unittest.c |