radeonsi/sqtt: use calloc instead of malloc
This makes sure the record is fully initialized and fixes RGP crashes or missing shaders. Cc: mesa-stable Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26774>
This commit is contained in:
committed by
Marge Bot
parent
b55a2065e0
commit
af8e6c9347
@@ -1027,7 +1027,7 @@ si_sqtt_add_code_object(struct si_context* sctx,
|
||||
struct rgp_code_object *code_object = &sctx->sqtt->rgp_code_object;
|
||||
struct rgp_code_object_record *record;
|
||||
|
||||
record = malloc(sizeof(struct rgp_code_object_record));
|
||||
record = calloc(1, sizeof(struct rgp_code_object_record));
|
||||
if (!record)
|
||||
return false;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user