diff options
author | Gustavo A. R. Silva <garsilva@embeddedor.com> | 2017-07-06 16:49:18 -0500 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2017-07-07 13:48:33 +0100 |
commit | da2629684822091bf15c6c14d8e33b75dfce8637 (patch) | |
tree | 0304b11bc79c62dde3ad513be278ce7aaabd27ca /drivers/i2c/i2c-slave-eeprom.c | |
parent | 8d67f64f7739464c352d4b167ed1748f3b2c1f44 (diff) | |
download | talos-op-linux-da2629684822091bf15c6c14d8e33b75dfce8637.tar.gz talos-op-linux-da2629684822091bf15c6c14d8e33b75dfce8637.zip |
regulator: axp20x: add NULL check on devm_kzalloc() return value
Check return value from call to devm_kzalloc()
in order to prevent a NULL pointer dereference.
This issue was detected using Coccinelle and the following semantic patch:
@@
expression x;
identifier fld;
@@
* x = devm_kzalloc(...);
... when != x == NULL
x->fld
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/i2c/i2c-slave-eeprom.c')
0 files changed, 0 insertions, 0 deletions