Adam Martinson : wined3d: Fix an oops/crash in context_destroy_gl_resources ().
Module: wine Branch: master Commit: f912e55610d055464680d8d05f60f54a4a8174f2 URL: http://source.winehq.org/git/wine.git/?a=commit;h=f912e55610d055464680d8d05f... Author: Adam Martinson <amartinson(a)codeweavers.com> Date: Fri Apr 29 16:48:25 2011 -0500 wined3d: Fix an oops/crash in context_destroy_gl_resources(). Introduced by 96b150929b0791c7c30ade49d55cedf2d608537e. --- dlls/wined3d/context.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c index 00a649b..9fecddd 100644 --- a/dlls/wined3d/context.c +++ b/dlls/wined3d/context.c @@ -989,7 +989,10 @@ static void context_destroy_gl_resources(struct wined3d_context *context) if (gl_info->supported[ARB_SYNC]) { - if (event_query->object.sync) GL_EXTCALL(glDeleteSync(event_query->object.sync)); + for (i = 0; i < context->free_event_query_count; ++i) + { + GL_EXTCALL(glDeleteSync(context->free_event_queries[i].sync)); + } } else if (gl_info->supported[APPLE_FENCE]) {
participants (1)
-
Alexandre Julliard