Commit 1a19ae43 authored by Qasim Ijaz's avatar Qasim Ijaz Committed by Jiri Kosina
Browse files

HID: wacom: fix memory leak on sysfs attribute creation failure



When sysfs_create_files() fails during wacom_initialize_remotes() the
fifo buffer is not freed leading to a memory leak.

Fix this by calling kfifo_free() before returning.

Fixes: 83e6b40e ("HID: wacom: EKR: have the wacom resources dynamically allocated")
Reviewed-by: default avatarPing Cheng <ping.cheng@wacom.com>
Cc: stable@vger.kernel.org
Signed-off-by: default avatarQasim Ijaz <qasdev00@gmail.com>
Signed-off-by: default avatarJiri Kosina <jkosina@suse.com>
parent 5ae416c5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment