wined3d: Don't record dirty areas in a readonly lock.

oldstable
Stefan Dösinger 2010-02-08 12:22:24 +01:00 committed by Alexandre Julliard
parent 454fb3c1da
commit 8625f0cdbf
1 changed files with 4 additions and 1 deletions

View File

@ -1086,7 +1086,10 @@ static HRESULT STDMETHODCALLTYPE buffer_Map(IWineD3DBuffer *iface, UINT offset,
TRACE("iface %p, offset %u, size %u, data %p, flags %#x\n", iface, offset, size, data, flags);
flags = buffer_sanitize_flags(flags);
if (!buffer_add_dirty_area(This, offset, size)) return E_OUTOFMEMORY;
if (!(flags & WINED3DLOCK_READONLY))
{
if (!buffer_add_dirty_area(This, offset, size)) return E_OUTOFMEMORY;
}
count = InterlockedIncrement(&This->lock_count);