[PATCH 2/4] wined3d: Pass a wined3d_device_gl pointer to wined3d_device_delete_opengl_contexts_cs().

Zebediah Figura zfigura at codeweavers.com
Thu Dec 9 11:45:22 CST 2021


On 12/9/21 06:53, Henri Verbeet wrote:
> On Thu, 9 Dec 2021 at 05:41, Zebediah Figura <zfigura at codeweavers.com> wrote:
>> +void wined3d_device_gl_delete_opengl_contexts_cs(void *object)
>>   {
>> +    struct wined3d_device_gl *device_gl = object;
>>       struct wined3d_swapchain_gl *swapchain_gl;
>> -    struct wined3d_device *device = object;
>>       struct wined3d_context_gl *context_gl;
>> -    struct wined3d_device_gl *device_gl;
>>       struct wined3d_context *context;
>> +    struct wined3d_device *device;
>>       struct wined3d_shader *shader;
>>
>> -    TRACE("device %p.\n", device);
>> -
>> -    device_gl = wined3d_device_gl(device);
>> +    device = &device_gl->d;
>>
> I think that TRACE is useful, and it was in fact explicitly added not
> that long ago in 7ba0cc908506b821abef10ea2748e55d9de10787.
> 

Indeed. I think my brain saw the trace in adapter_gl_uninit_3d() and 
decided that it was close enough, without realizing that there was a CS 
boundary, plus a few other wined3d calls, between the two. I'll resend 
with the trace restored.



More information about the wine-devel mailing list