Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
5ecc08e3
Commit
5ecc08e3
authored
Mar 01, 2015
by
Sebastian Lackner
Committed by
Alexandre Julliard
Mar 27, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
browseui: Avoid race-conditions when progress dialog is released before thread terminates.
parent
73a68b06
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
progressdlg.c
dlls/browseui/progressdlg.c
+6
-0
No files found.
dlls/browseui/progressdlg.c
View file @
5ecc08e3
...
...
@@ -235,6 +235,7 @@ static DWORD WINAPI dialog_thread(LPVOID lpParameter)
/* Note: until we set the hEvent in WM_INITDIALOG, the ProgressDialog object
* is protected by the critical section held by StartProgress */
struct
create_params
*
params
=
lpParameter
;
ProgressDialog
*
This
=
params
->
This
;
HWND
hwnd
;
MSG
msg
;
...
...
@@ -252,6 +253,7 @@ static DWORD WINAPI dialog_thread(LPVOID lpParameter)
}
}
IProgressDialog_Release
(
&
This
->
IProgressDialog_iface
);
return
0
;
}
...
...
@@ -341,10 +343,14 @@ static HRESULT WINAPI ProgressDialog_StartProgressDialog(IProgressDialog *iface,
return
S_OK
;
/* as on XP */
}
This
->
dwFlags
=
dwFlags
;
params
.
This
=
This
;
params
.
hwndParent
=
hwndParent
;
params
.
hEvent
=
CreateEventW
(
NULL
,
TRUE
,
FALSE
,
NULL
);
/* thread holds one reference to ensure clean shutdown */
IProgressDialog_AddRef
(
&
This
->
IProgressDialog_iface
);
hThread
=
CreateThread
(
NULL
,
0
,
dialog_thread
,
&
params
,
0
,
NULL
);
WaitForSingleObject
(
params
.
hEvent
,
INFINITE
);
CloseHandle
(
params
.
hEvent
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment