diff options
author | Zichen Xie <zichenxie0106@gmail.com> | 2024-11-15 08:43:36 +0300 |
---|---|---|
committer | Shuah Khan <skhan@linuxfoundation.org> | 2024-11-20 01:17:51 +0300 |
commit | 435c20eed572a95709b1536ff78832836b2f91b1 (patch) | |
tree | 968a1bb24e0f22e21e59b07529fa55824eb381a6 /tools/perf/scripts/python/syscall-counts-by-pid.py | |
parent | aadf9cb1f0864bff45e3a3e5590af97097dd7317 (diff) | |
download | linux-435c20eed572a95709b1536ff78832836b2f91b1.tar.xz |
kunit: Fix potential null dereference in kunit_device_driver_test()
kunit_kzalloc() may return a NULL pointer, dereferencing it without
NULL check may lead to NULL dereference.
Add a NULL check for test_state.
Link: https://lore.kernel.org/r/20241115054335.21673-1-zichenxie0106@gmail.com
Fixes: d03c720e03bd ("kunit: Add APIs for managing devices")
Signed-off-by: Zichen Xie <zichenxie0106@gmail.com>
Cc: stable@vger.kernel.org
Reviewed-by: David Gow <davidgow@google.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python/syscall-counts-by-pid.py')
0 files changed, 0 insertions, 0 deletions