Skip to content
Commit b034ed50 authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Jiri Kosina
Browse files

HID: core: fix NULL pointer dereference



There is a NULL pointer dereference in case memory resources
for *parse* are not successfully allocated.

Fix this by adding a new goto label and make the execution
path jump to it in case vzalloc() fails.

Addresses-Coverity-ID: 1473081 ("Dereference after null check")
Fixes: b2dd9f2e ("HID: core: fix memory leak on probe")
Signed-off-by: default avatarGustavo A. R. Silva <gustavo@embeddedor.com>
Reviewed-by: default avatarStefan Agner <stefan@agner.ch>
Signed-off-by: default avatarJiri Kosina <jkosina@suse.cz>
parent 0d6c3011
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment