Commit fcee0558 authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Simply inline dumpResources().

parent 5ce986f1
......@@ -610,9 +610,17 @@ static ULONG WINAPI IWineD3DDeviceImpl_Release(IWineD3DDevice *iface) {
/* NOTE: You must release the parent if the object was created via a callback
** ***************************/
if (!list_empty(&This->resources)) {
if (!list_empty(&This->resources))
{
IWineD3DResourceImpl *resource;
FIXME("(%p) Device released with resources still bound, acceptable but unexpected\n", This);
dumpResources(&This->resources);
LIST_FOR_EACH_ENTRY(resource, &This->resources, IWineD3DResourceImpl, resource.resource_list_entry)
{
WINED3DRESOURCETYPE type = IWineD3DResource_GetType((IWineD3DResource *)resource);
FIXME("Leftover resource %p with type %s (%#x).\n",
resource, debug_d3dresourcetype(type), type);
}
}
if(This->contexts) ERR("Context array not freed!\n");
......
......@@ -247,11 +247,3 @@ HRESULT resource_get_parent(IWineD3DResource *iface, IUnknown **pParent)
*pParent = This->resource.parent;
return WINED3D_OK;
}
void dumpResources(struct list *list) {
IWineD3DResourceImpl *resource;
LIST_FOR_EACH_ENTRY(resource, list, IWineD3DResourceImpl, resource.resource_list_entry) {
FIXME("Leftover resource %p with type %d,%s\n", resource, IWineD3DResource_GetType((IWineD3DResource *) resource), debug_d3dresourcetype(IWineD3DResource_GetType((IWineD3DResource *) resource)));
}
}
......@@ -1571,9 +1571,6 @@ HRESULT wined3d_init(IWineD3DImpl *wined3d, UINT version, IUnknown *parent) DECL
BOOL wined3d_register_window(HWND window, struct IWineD3DDeviceImpl *device) DECLSPEC_HIDDEN;
void wined3d_unregister_window(HWND window) DECLSPEC_HIDDEN;
/* A helper function that dumps a resource list */
void dumpResources(struct list *list) DECLSPEC_HIDDEN;
/*****************************************************************************
* IWineD3DDevice implementation structure
*/
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment