Henri Verbeet : wined3d: Synchronise WINED3D_CS_OP_UNLOAD_RESOURCE resource access.

Alexandre Julliard julliard at winehq.org
Thu Aug 11 09:37:47 CDT 2016


Module: wine
Branch: master
Commit: af54f9b93a4632a76ee14ed98902a31f2e7c3472
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=af54f9b93a4632a76ee14ed98902a31f2e7c3472

Author: Henri Verbeet <hverbeet at codeweavers.com>
Date:   Wed Aug 10 18:44:46 2016 +0200

wined3d: Synchronise WINED3D_CS_OP_UNLOAD_RESOURCE resource access.

Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/wined3d/cs.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c
index 0d5c151..c9d728c 100644
--- a/dlls/wined3d/cs.c
+++ b/dlls/wined3d/cs.c
@@ -1256,6 +1256,7 @@ static void wined3d_cs_exec_unload_resource(struct wined3d_cs *cs, const void *d
     struct wined3d_resource *resource = op->resource;
 
     resource->resource_ops->resource_unload(resource);
+    wined3d_resource_release(resource);
 }
 
 void wined3d_cs_emit_unload_resource(struct wined3d_cs *cs, struct wined3d_resource *resource)
@@ -1266,6 +1267,8 @@ void wined3d_cs_emit_unload_resource(struct wined3d_cs *cs, struct wined3d_resou
     op->opcode = WINED3D_CS_OP_UNLOAD_RESOURCE;
     op->resource = resource;
 
+    wined3d_resource_acquire(resource);
+
     cs->ops->submit(cs);
 }
 




More information about the wine-cvs mailing list