Module: wine Branch: master Commit: bcffa12484e311e18f8ef191673028172e05b130 URL: http://source.winehq.org/git/wine.git/?a=commit;h=bcffa12484e311e18f8ef19167...
Author: Jacek Caban jacek@codeweavers.com Date: Thu May 26 17:01:51 2011 +0200
shdocvw: Abort pending tasks on DocHost destruction.
---
dlls/shdocvw/dochost.c | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-)
diff --git a/dlls/shdocvw/dochost.c b/dlls/shdocvw/dochost.c index 407bbf9..97e5f77 100644 --- a/dlls/shdocvw/dochost.c +++ b/dlls/shdocvw/dochost.c @@ -62,6 +62,16 @@ LRESULT process_dochost_tasks(DocHost *This) return 0; }
+static void abort_dochost_tasks(DocHost *This) +{ + task_header_t *task, *cursor; + + LIST_FOR_EACH_ENTRY_SAFE(task, cursor, &This->task_queue, task_header_t, entry) { + list_remove(&task->entry); + task->destr(task); + } +} + static void notif_complete(DocHost *This, DISPID dispid) { DISPPARAMS dispparams; @@ -876,6 +886,7 @@ void DocHost_Init(DocHost *This, IDispatch *disp, const IDocHostContainerVtbl* c
void DocHost_Release(DocHost *This) { + abort_dochost_tasks(This); release_dochost_client(This); DocHost_ClientSite_Release(This);