OSDN Git Service

regulator: cros-ec-regulator: Add NULL test for devm_kmemdup call
authorAxel Lin <axel.lin@ingics.com>
Sun, 2 Aug 2020 03:25:09 +0000 (11:25 +0800)
committerMark Brown <broonie@kernel.org>
Tue, 4 Aug 2020 12:24:37 +0000 (13:24 +0100)
commitce4109005770ff6f160e1424928b9cc696e8c8f2
tree8f8cf28034435c6916d3652c38be928b3d22bdfa
parentbcb3b2a7639db2412875520cddc3abd179068793
regulator: cros-ec-regulator: Add NULL test for devm_kmemdup call

Fix possible NULL pointer dereference.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Link: https://lore.kernel.org/r/20200802032509.305425-1-axel.lin@ingics.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/regulator/cros-ec-regulator.c