On Tue, 01 Sep 2026 09:08:38 +0000, Chaithanya Lagisetty wrote:
> vcpu_get_reg_list() allocates reg_list with calloc() and immediately
> dereferences it via reg_list->n without checking for allocation failure,
> unlike every other allocation in this file which is guarded by
> TEST_ASSERT(). If calloc() returns NULL the test crashes with a NULL
> pointer dereference instead of a clean failure message.
> 
> Add the missing TEST_ASSERT() check.
> 
> [...]

Applied to kvm-x86 selftests, thanks!

[1/1] selftests: kvm: Check calloc() return in vcpu_get_reg_list()
      https://github.com/kvm-x86/linux/commit/b57917fc2b26

--
https://github.com/kvm-x86/linux/tree/next

Reply via email to