mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-28 05:20:23 +01:00
d3d12: Handle a null threaded context
When GALLIUM_THREAD=0, the threaded context doesn't get created and the following lines would fault. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35248>
This commit is contained in:
parent
0c0f6c6df1
commit
47f4d3e701
1 changed files with 4 additions and 2 deletions
|
|
@ -500,8 +500,10 @@ d3d12_context_create(struct pipe_screen *pscreen, void *priv, unsigned flags)
|
|||
d3d12_replace_buffer_storage,
|
||||
NULL,
|
||||
&ctx->threaded_context);
|
||||
ctx->threaded_context->bytes_replaced_limit = 1024 * 1024 * 1024; /* 1GiB */
|
||||
threaded_context_init_bytes_mapped_limit(ctx->threaded_context, 4);
|
||||
if (ctx->threaded_context) {
|
||||
ctx->threaded_context->bytes_replaced_limit = 1024 * 1024 * 1024; /* 1GiB */
|
||||
threaded_context_init_bytes_mapped_limit(ctx->threaded_context, 4);
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue