[PATCH 1/2] wined3d: Zero-initialize the swapchain context array.
Matteo Bruni
mbruni at codeweavers.com
Fri May 31 04:08:10 CDT 2019
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47255
Signed-off-by: Matteo Bruni <mbruni at codeweavers.com>
---
Fixes a regression from commit db201072655946662c041a66ee434c30c245e5b0.
dlls/wined3d/swapchain.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/wined3d/swapchain.c b/dlls/wined3d/swapchain.c
index fbedd7470df..48d0920554d 100644
--- a/dlls/wined3d/swapchain.c
+++ b/dlls/wined3d/swapchain.c
@@ -892,7 +892,7 @@ static HRESULT swapchain_init(struct wined3d_swapchain *swapchain, struct wined3
if (!(device->wined3d->flags & WINED3D_NO3D))
{
- if (!(swapchain->context = heap_alloc(sizeof(*swapchain->context))))
+ if (!(swapchain->context = heap_alloc_zero(sizeof(*swapchain->context))))
{
ERR("Failed to create the context array.\n");
hr = E_OUTOFMEMORY;
--
2.21.0
More information about the wine-devel
mailing list