On 15.04.2013 10:24, Stefan Dösinger wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Am 2013-04-14 16:53, schrieb Rico Schüller:
+    if (iface->lpVtbl != (const IDirect3DBaseTexture8Vtbl
*)&Direct3DTexture8_Vtbl +            && iface->lpVtbl != (const
IDirect3DBaseTexture8Vtbl *)&Direct3DCubeTexture8_Vtbl +
&& iface->lpVtbl != (const IDirect3DBaseTexture8Vtbl
*)&Direct3DVolumeTexture8_Vtbl) +    { +        WARN("%p is not a
valid IDirect3DBaseTexture8 interface.\n", iface); +        return
NULL; +    }
A test would be a good idea.

Are you sure that the assert is the actual problem, and not some
memory corruption that changes the vtable poiner? What does e.g.
GetTexture do after a bogous SetTexture call?

Well, the app sets an already released texture. As we access some members (in this case wined3d_texture) we may get some trouble when the memory is reused with some other data as we have the guilty memory still bound somewhere in the pipeline.

I'm not sure what GetTexture does, a test might show it (I'll have a look). The problem might be, that we use some members, which native probably doesn't do in SetTexture. You couldn't call GetTexture in wine with uninitialized memory as we do currently, that's why I think using NULL is the way to go.

Please have a look at http://bugs.winehq.org/show_bug.cgi?id=33055 . Well I think there might be some memory corruption somewhere, but it doesn't have anything to do with the this bug as we use already freed memory in our implementation.

Cheers
Rico


Reply via email to