Commit 6bc69c27 authored by Stefan Dösinger's avatar Stefan Dösinger Committed by Alexandre Julliard

wined3d: Don't create a DIB section in gdi_surface_map.

parent de60681b
......@@ -1480,21 +1480,6 @@ static void gdi_surface_map(struct wined3d_surface *surface, const RECT *rect, D
{
TRACE("surface %p, rect %s, flags %#x.\n",
surface, wine_dbgstr_rect(rect), flags);
if (!(surface->flags & SFLAG_DIBSECTION))
{
HRESULT hr;
/* This happens on gdi surfaces if the application set a user pointer
* and resets it. Recreate the DIB section. */
if (FAILED(hr = surface_create_dib_section(surface)))
{
ERR("Failed to create dib section, hr %#x.\n", hr);
return;
}
wined3d_resource_free_sysmem(&surface->resource);
surface->resource.allocatedMemory = surface->dib.bitmap_data;
}
}
static void gdi_surface_unmap(struct wined3d_surface *surface)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment