d3dcompiler: Check shader for NULL.

Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Matteo Bruni 2020-06-17 17:27:26 +02:00 committed by Alexandre Julliard
parent 749ef9b218
commit 7d92b1abbd
1 changed files with 1 additions and 1 deletions

View File

@ -805,7 +805,7 @@ static HRESULT compile_shader(const char *preproc_shader, const char *target, co
if (FAILED(blob_hr = D3DCreateBlob(size, &buffer)))
{
HeapFree(GetProcessHeap(), 0, messages);
if (*shader)
if (shader && *shader)
{
ID3D10Blob_Release(*shader);
*shader = NULL;