[DDRAW] Sync with Wine 3.0. CORE-14225
[reactos.git] / dll / directx / wine / ddraw / vertexbuffer.c
index 04d7adb..155a8dd 100644 (file)
@@ -159,6 +159,9 @@ static HRESULT WINAPI d3d_vertex_buffer7_Lock(IDirect3DVertexBuffer7 *iface,
 
     TRACE("iface %p, flags %#x, data %p, data_size %p.\n", iface, flags, data, data_size);
 
+    if (buffer->version != 7)
+        flags &= ~(DDLOCK_NOOVERWRITE | DDLOCK_DISCARDCONTENTS);
+
     /* Writeonly: Pointless. Event: Unsupported by native according to the sdk
      * nosyslock: Not applicable
      */
@@ -246,7 +249,7 @@ static HRESULT WINAPI d3d_vertex_buffer7_Unlock(IDirect3DVertexBuffer7 *iface)
  *  SrcIndex: Index of the first vertex in the src buffer to process
  *  D3DDevice: Device to use for transformation
  *  Flags: 0 for default, D3DPV_DONOTCOPYDATA to prevent copying
- *         unchaned vertices
+ *         unchanged vertices
  *
  * Returns:
  *  D3D_OK on success