I think that the series could be split better. One way I'd suggest is to introduce a helper like: ``` void destroy_dispatch(DispatchEx *dispex) { dispex->info->desc->vtbl->unlink(disex); dispex->info->desc->vtbl->destroy(dispex); // maybe if (vtbl->destroy) vtbl->destroy() else free() ?? } ``` Then you could convert all objects to call `destroy_dispatch` in their `Release` implementation in a series of self-contained patches. Once all objects are converted, changing it further will require much less invasive module-wide patches.
Since we will need a lot of unlinking, maybe a helper like: ``` void unlink(void *ptr) { IUnknown **unk_ptr = ptr, unk = *unk_ptr; *unk_ptr = NULL; if (unk) IUnknown_Release(unk); } ``` would make worth it.