Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
e874408d
Commit
e874408d
authored
Jul 19, 2005
by
Robert Shearman
Committed by
Alexandre Julliard
Jul 19, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Delete the stub manager outside of the apartment critical section
because the deletion may require the object to re-enter the apartment.
parent
48a52d09
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
6 deletions
+10
-6
stubmanager.c
dlls/ole32/stubmanager.c
+10
-6
No files found.
dlls/ole32/stubmanager.c
View file @
e874408d
...
...
@@ -96,15 +96,13 @@ struct stub_manager *new_stub_manager(APARTMENT *apt, IUnknown *object, MSHLFLAG
return
sm
;
}
/*
m->apt->cs must be held on entry to
this function */
/*
caller must remove stub manager from apartment prior to calling
this function */
static
void
stub_manager_delete
(
struct
stub_manager
*
m
)
{
struct
list
*
cursor
;
TRACE
(
"destroying %p (oid=%s)
\n
"
,
m
,
wine_dbgstr_longlong
(
m
->
oid
));
list_remove
(
&
m
->
entry
);
/* release every ifstub */
while
((
cursor
=
list_head
(
&
m
->
ifstubs
)))
{
...
...
@@ -230,10 +228,16 @@ ULONG stub_manager_int_release(struct stub_manager *This)
TRACE
(
"after %ld
\n
"
,
refs
);
/* remove from apartment so no other thread can access it... */
if
(
!
refs
)
stub_manager_delete
(
This
);
list_remove
(
&
This
->
entry
);
LeaveCriticalSection
(
&
apt
->
cs
);
/* ... so now we can delete it without being inside the apartment critsec */
if
(
!
refs
)
stub_manager_delete
(
This
);
return
refs
;
}
...
...
@@ -505,9 +509,9 @@ void stub_manager_release_marshal_data(struct stub_manager *m, ULONG refs)
break
;
}
stub_manager_ext_release
(
m
,
refs
);
LeaveCriticalSection
(
&
m
->
lock
);
stub_manager_ext_release
(
m
,
refs
);
}
/* is an ifstub table marshaled? */
...
...
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