Files
linux/drivers/pcmcia
Wentao Liang 4a81f78caa pcmcia: Add error handling for add_interval() in do_validate_mem()
In the do_validate_mem(), the call to add_interval() does not
handle errors. If kmalloc() fails in add_interval(), it could
result in a null pointer being inserted into the linked list,
leading to illegal memory access when sub_interval() is called
next.

This patch adds an error handling for the add_interval(). If
add_interval() returns an error, the function will return early
with the error code.

Fixes: 7b4884ca88 ("pcmcia: validate late-added resources")
Signed-off-by: Wentao Liang <vulab@iscas.ac.cn>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
2025-08-16 15:49:58 +02:00
..
2025-04-10 09:33:52 -05:00
2025-08-16 15:36:08 +02:00
2025-08-16 15:37:47 +02:00
2025-08-16 15:37:47 +02:00
2018-12-04 22:37:38 +00:00
2023-09-03 10:45:47 +02:00