Fix use-after-free with ID3D12InfoQueue messages

このコミットが含まれているのは:
Sergio Pedri committed 2022-07-31 23:26:09 +02:00
1 親 ab8ca32770
コミット 5cb00a8924
1ファイル変更
+5 -5
+5 -5
ファイルの表示
@@ -160,17 +160,17 @@ partial class DeviceHelper
{
builder.Append($"[Description]: \"{new string(message->pDescription)}\"");
}
if (message->Severity is D3D12_MESSAGE_SEVERITY_ERROR or D3D12_MESSAGE_SEVERITY_CORRUPTION or D3D12_MESSAGE_SEVERITY_WARNING)
{
hasErrorsOrWarnings = true;
}
}
finally
{
NativeMemory.Free(message);
}
if (message->Severity is D3D12_MESSAGE_SEVERITY_ERROR or D3D12_MESSAGE_SEVERITY_CORRUPTION or D3D12_MESSAGE_SEVERITY_WARNING)
{
hasErrorsOrWarnings = true;
}
Trace.WriteLine(builder);
}