Henri Verbeet : wined3d: Don't bother allocating "free_timestamp_queries" in context_create().

Alexandre Julliard julliard at winehq.org
Fri Apr 19 17:30:47 CDT 2019


Module: wine
Branch: master
Commit: 9d7d68747b06a03893df99c4beea36b762508603
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=9d7d68747b06a03893df99c4beea36b762508603

Author: Henri Verbeet <hverbeet at codeweavers.com>
Date:   Fri Apr 19 21:22:49 2019 +0430

wined3d: Don't bother allocating "free_timestamp_queries" in context_create().

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

---

 dlls/wined3d/context.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c
index ab5d9c3..f4179d7 100644
--- a/dlls/wined3d/context.c
+++ b/dlls/wined3d/context.c
@@ -1896,12 +1896,7 @@ struct wined3d_context *context_create(struct wined3d_swapchain *swapchain,
     if (!(context = heap_alloc_zero(sizeof(*context))))
         return NULL;
 
-    context->free_timestamp_query_size = 4;
-    if (!(context->free_timestamp_queries = heap_calloc(context->free_timestamp_query_size,
-            sizeof(*context->free_timestamp_queries))))
-        goto out;
     list_init(&context->timestamp_queries);
-
     list_init(&context->occlusion_queries);
     list_init(&context->fences);
     list_init(&context->so_statistics_queries);
@@ -1982,7 +1977,6 @@ out:
         wined3d_release_dc(swapchain->win_handle, context->hdc);
     device->shader_backend->shader_free_context_data(context);
     device->adapter->fragment_pipe->free_context_data(context);
-    heap_free(context->free_timestamp_queries);
     heap_free(context);
     return NULL;
 }




More information about the wine-cvs mailing list