mirror of
https://github.com/wolfpld/tracy.git
synced 2025-03-20 07:40:02 +08:00
Harden against uninitialized rpmalloc.
Initialize rpmalloc either by explicitly calling InitRPMallocThread(), or by forcing initialization of thread local variables block.
This commit is contained in:
@@ -271,6 +271,7 @@ private:
|
||||
|
||||
static inline VkCtx* CreateVkContext( VkPhysicalDevice physdev, VkDevice device, VkQueue queue, VkCommandBuffer cmdbuf )
|
||||
{
|
||||
InitRPMallocThread();
|
||||
auto ctx = (VkCtx*)tracy_malloc( sizeof( VkCtx ) );
|
||||
new(ctx) VkCtx( physdev, device, queue, cmdbuf );
|
||||
return ctx;
|
||||
|
||||
Reference in New Issue
Block a user