diff options
author | Pan Bian | 2016-12-03 10:29:28 +0100 |
---|---|---|
committer | Greg Kroah-Hartman | 2017-01-10 21:46:41 +0100 |
commit | ddc5c9a37be4517270453ce909d3dfcc8de58230 (patch) | |
tree | bdf83a866802e27140fda6be54b63ad4ca50a8e3 /drivers/misc/lkdtm.h | |
parent | Drivers: hv: util: Backup: Fix a rescind processing issue (diff) | |
download | kernel-qcow2-linux-ddc5c9a37be4517270453ce909d3dfcc8de58230.tar.gz kernel-qcow2-linux-ddc5c9a37be4517270453ce909d3dfcc8de58230.tar.xz kernel-qcow2-linux-ddc5c9a37be4517270453ce909d3dfcc8de58230.zip |
misc: set error code when devm_kstrdup fails
In function sram_reserve_regions(), the value of return variable ret
should be negative on failures. However, the value of ret may be 0 even
if the call to devm_kstrdup() returns a NULL pointer. This patch
explicitly assigns "-ENOMEM" to ret on the path that devm_kstrdup()
fails.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188651
Signed-off-by: Pan Bian <bianpan2016@163.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/lkdtm.h')
0 files changed, 0 insertions, 0 deletions