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
2f053965
Commit
2f053965
authored
Sep 01, 2011
by
Octavian Voicu
Committed by
Alexandre Julliard
Sep 01, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vbscript: Fix possible memory leak/crash caused by race condition in VBScriptParse_InitNew.
parent
45725be9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
vbscript.c
dlls/vbscript/vbscript.c
+3
-3
No files found.
dlls/vbscript/vbscript.c
View file @
2f053965
...
...
@@ -348,7 +348,7 @@ static ULONG WINAPI VBScriptParse_Release(IActiveScriptParse *iface)
static
HRESULT
WINAPI
VBScriptParse_InitNew
(
IActiveScriptParse
*
iface
)
{
VBScript
*
This
=
impl_from_IActiveScriptParse
(
iface
);
script_ctx_t
*
ctx
;
script_ctx_t
*
ctx
,
*
old_ctx
;
TRACE
(
"(%p)
\n
"
,
This
);
...
...
@@ -359,8 +359,8 @@ static HRESULT WINAPI VBScriptParse_InitNew(IActiveScriptParse *iface)
if
(
!
ctx
)
return
E_OUTOFMEMORY
;
ctx
=
InterlockedCompareExchangePointer
((
void
**
)
&
This
->
ctx
,
ctx
,
NULL
);
if
(
ctx
)
{
old_
ctx
=
InterlockedCompareExchangePointer
((
void
**
)
&
This
->
ctx
,
ctx
,
NULL
);
if
(
old_
ctx
)
{
destroy_script
(
ctx
);
return
E_UNEXPECTED
;
}
...
...
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