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
16fab1a4
Commit
16fab1a4
authored
Nov 21, 2022
by
Alex Henrie
Committed by
Alexandre Julliard
Nov 22, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ieframe: Use standard C functions for memory allocation.
parent
0d294ad2
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
58 additions
and
76 deletions
+58
-76
dochost.c
dlls/ieframe/dochost.c
+10
-10
events.c
dlls/ieframe/events.c
+7
-8
ie.c
dlls/ieframe/ie.c
+1
-1
ieframe.h
dlls/ieframe/ieframe.h
+0
-17
iexplore.c
dlls/ieframe/iexplore.c
+8
-8
intshcut.c
dlls/ieframe/intshcut.c
+16
-16
navigate.c
dlls/ieframe/navigate.c
+8
-8
oleobject.c
dlls/ieframe/oleobject.c
+2
-2
shellbrowser.c
dlls/ieframe/shellbrowser.c
+2
-2
shelluihelper.c
dlls/ieframe/shelluihelper.c
+2
-2
webbrowser.c
dlls/ieframe/webbrowser.c
+2
-2
No files found.
dlls/ieframe/dochost.c
View file @
16fab1a4
...
...
@@ -269,7 +269,7 @@ static void ready_state_task_destr(task_header_t *_task)
ready_state_task_t
*
task
=
(
ready_state_task_t
*
)
_task
;
IUnknown_Release
(
task
->
doc
);
heap_
free
(
task
);
free
(
task
);
}
static
void
ready_state_proc
(
DocHost
*
This
,
task_header_t
*
_task
)
...
...
@@ -282,7 +282,7 @@ static void ready_state_proc(DocHost *This, task_header_t *_task)
static
void
push_ready_state_task
(
DocHost
*
This
,
READYSTATE
ready_state
)
{
ready_state_task_t
*
task
=
heap_
alloc
(
sizeof
(
ready_state_task_t
));
ready_state_task_t
*
task
=
m
alloc
(
sizeof
(
ready_state_task_t
));
IUnknown_AddRef
(
This
->
document
);
task
->
doc
=
This
->
document
;
...
...
@@ -293,7 +293,7 @@ static void push_ready_state_task(DocHost *This, READYSTATE ready_state)
static
void
object_available_task_destr
(
task_header_t
*
task
)
{
heap_
free
(
task
);
free
(
task
);
}
static
void
object_available_proc
(
DocHost
*
This
,
task_header_t
*
task
)
...
...
@@ -331,7 +331,7 @@ HRESULT dochost_object_available(DocHost *This, IUnknown *doc)
/* FIXME: Call SetAdvise */
task
=
heap_
alloc
(
sizeof
(
*
task
));
task
=
m
alloc
(
sizeof
(
*
task
));
push_dochost_task
(
This
,
task
,
object_available_proc
,
object_available_task_destr
,
FALSE
);
hres
=
get_doc_ready_state
(
This
,
&
ready_state
);
...
...
@@ -388,7 +388,7 @@ static void free_travellog_entry(travellog_entry_t *entry)
IStream_Release
(
entry
->
stream
);
entry
->
stream
=
NULL
;
}
heap_
free
(
entry
->
url
);
free
(
entry
->
url
);
entry
->
url
=
NULL
;
}
...
...
@@ -436,7 +436,7 @@ static void update_travellog(DocHost *This)
}
if
(
!
This
->
travellog
.
log
)
{
This
->
travellog
.
log
=
heap_
alloc
(
4
*
sizeof
(
*
This
->
travellog
.
log
));
This
->
travellog
.
log
=
m
alloc
(
4
*
sizeof
(
*
This
->
travellog
.
log
));
if
(
!
This
->
travellog
.
log
)
return
;
...
...
@@ -444,7 +444,7 @@ static void update_travellog(DocHost *This)
}
else
if
(
This
->
travellog
.
size
<
This
->
travellog
.
position
+
1
)
{
travellog_entry_t
*
new_travellog
;
new_travellog
=
heap_realloc
(
This
->
travellog
.
log
,
This
->
travellog
.
size
*
2
*
sizeof
(
*
This
->
travellog
.
log
));
new_travellog
=
realloc
(
This
->
travellog
.
log
,
This
->
travellog
.
size
*
2
*
sizeof
(
*
This
->
travellog
.
log
));
if
(
!
new_travellog
)
return
;
...
...
@@ -460,7 +460,7 @@ static void update_travellog(DocHost *This)
new_entry
=
This
->
travellog
.
log
+
This
->
travellog
.
position
;
new_entry
->
url
=
heap_strdupW
(
This
->
url
);
new_entry
->
url
=
wcsdup
(
This
->
url
);
TRACE
(
"Adding %s at %d
\n
"
,
debugstr_w
(
This
->
url
),
This
->
travellog
.
position
);
if
(
!
new_entry
->
url
)
return
;
...
...
@@ -1169,7 +1169,7 @@ void DocHost_Release(DocHost *This)
while
(
This
->
travellog
.
length
)
free_travellog_entry
(
This
->
travellog
.
log
+
--
This
->
travellog
.
length
);
heap_
free
(
This
->
travellog
.
log
);
free
(
This
->
travellog
.
log
);
heap_
free
(
This
->
url
);
free
(
This
->
url
);
}
dlls/ieframe/events.c
View file @
16fab1a4
...
...
@@ -181,7 +181,7 @@ static ULONG WINAPI EnumConnections_Release(IEnumConnections *iface)
if
(
!
ref
)
{
IConnectionPoint_Release
(
&
This
->
cp
->
IConnectionPoint_iface
);
heap_
free
(
This
);
free
(
This
);
}
return
ref
;
...
...
@@ -324,10 +324,9 @@ static HRESULT WINAPI ConnectionPoint_Advise(IConnectionPoint *iface, IUnknown *
}
if
(
i
==
This
->
sinks_size
)
This
->
sinks
=
heap_realloc
(
This
->
sinks
,
(
++
This
->
sinks_size
)
*
sizeof
(
*
This
->
sinks
));
This
->
sinks
=
realloc
(
This
->
sinks
,
(
++
This
->
sinks_size
)
*
sizeof
(
*
This
->
sinks
));
}
else
{
This
->
sinks
=
heap_
alloc
(
sizeof
(
*
This
->
sinks
));
This
->
sinks
=
m
alloc
(
sizeof
(
*
This
->
sinks
));
This
->
sinks_size
=
1
;
i
=
0
;
}
...
...
@@ -361,7 +360,7 @@ static HRESULT WINAPI ConnectionPoint_EnumConnections(IConnectionPoint *iface,
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
ppEnum
);
ret
=
heap_
alloc
(
sizeof
(
*
ret
));
ret
=
m
alloc
(
sizeof
(
*
ret
));
if
(
!
ret
)
return
E_OUTOFMEMORY
;
...
...
@@ -402,7 +401,7 @@ void call_sink(ConnectionPoint *This, DISPID dispid, DISPPARAMS *dispparams)
static
void
ConnectionPoint_Create
(
REFIID
riid
,
ConnectionPoint
**
cp
,
IConnectionPointContainer
*
container
)
{
ConnectionPoint
*
ret
=
heap_
alloc
(
sizeof
(
ConnectionPoint
));
ConnectionPoint
*
ret
=
m
alloc
(
sizeof
(
ConnectionPoint
));
ret
->
IConnectionPoint_iface
.
lpVtbl
=
&
ConnectionPointVtbl
;
...
...
@@ -424,8 +423,8 @@ static void ConnectionPoint_Destroy(ConnectionPoint *This)
IDispatch_Release
(
This
->
sinks
[
i
]);
}
heap_
free
(
This
->
sinks
);
heap_
free
(
This
);
free
(
This
->
sinks
);
free
(
This
);
}
void
ConnectionPointContainer_Init
(
ConnectionPointContainer
*
This
,
IUnknown
*
impl
)
...
...
dlls/ieframe/ie.c
View file @
16fab1a4
...
...
@@ -92,7 +92,7 @@ static ULONG WINAPI InternetExplorer_Release(IWebBrowser2 *iface)
if
(
This
->
frame_hwnd
)
DestroyWindow
(
This
->
frame_hwnd
);
list_remove
(
&
This
->
entry
);
heap_
free
(
This
);
free
(
This
);
released_obj
();
}
...
...
dlls/ieframe/ieframe.h
View file @
16fab1a4
...
...
@@ -37,7 +37,6 @@
#include "shdeprecated.h"
#include "docobjectservice.h"
#include "wine/heap.h"
#include "wine/list.h"
typedef
struct
ConnectionPoint
ConnectionPoint
;
...
...
@@ -340,22 +339,6 @@ static inline void unlock_module(void) {
InterlockedDecrement
(
&
module_ref
);
}
static
inline
LPWSTR
heap_strdupW
(
LPCWSTR
str
)
{
LPWSTR
ret
=
NULL
;
if
(
str
)
{
DWORD
size
;
size
=
(
lstrlenW
(
str
)
+
1
)
*
sizeof
(
WCHAR
);
ret
=
heap_alloc
(
size
);
if
(
ret
)
memcpy
(
ret
,
str
,
size
);
}
return
ret
;
}
static
inline
LPWSTR
co_strdupW
(
LPCWSTR
str
)
{
WCHAR
*
ret
=
CoTaskMemAlloc
((
lstrlenW
(
str
)
+
1
)
*
sizeof
(
WCHAR
));
...
...
dlls/ieframe/iexplore.c
View file @
16fab1a4
...
...
@@ -116,7 +116,7 @@ static void free_fav_menu_data(HMENU menu)
int
i
;
for
(
i
=
0
;
(
url
=
get_fav_url_from_id
(
menu
,
ID_BROWSE_GOTOFAV_FIRST
+
i
));
i
++
)
heap_
free
(
url
);
free
(
url
);
}
static
int
get_menu_item_count
(
HMENU
menu
)
...
...
@@ -152,7 +152,7 @@ static void add_fav_to_menu(HMENU favmenu, HMENU menu, LPWSTR title, LPCWSTR url
return
;
}
urlbuf
=
heap_alloc
((
lstrlenW
(
url
)
+
1
)
*
sizeof
(
WCHAR
));
urlbuf
=
malloc
((
wcslen
(
url
)
+
1
)
*
sizeof
(
WCHAR
));
if
(
!
urlbuf
)
return
;
...
...
@@ -801,7 +801,7 @@ static HRESULT create_ie(InternetExplorer **ret_obj)
{
InternetExplorer
*
ret
;
ret
=
heap_alloc_zero
(
sizeof
(
InternetExplorer
));
ret
=
calloc
(
1
,
sizeof
(
InternetExplorer
));
if
(
!
ret
)
return
E_OUTOFMEMORY
;
...
...
@@ -888,7 +888,7 @@ static ULONG WINAPI InternetExplorerManager_Release(IInternetExplorerManager *if
if
(
ref
==
0
)
{
HeapFree
(
GetProcessHeap
(),
0
,
This
);
free
(
This
);
released_obj
();
}
...
...
@@ -917,7 +917,7 @@ HRESULT WINAPI InternetExplorerManager_Create(IClassFactory *iface, IUnknown *pO
TRACE
(
"(%p %s %p)
\n
"
,
pOuter
,
debugstr_guid
(
riid
),
ppv
);
if
(
!
(
ret
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
ret
))))
if
(
!
(
ret
=
calloc
(
1
,
sizeof
(
*
ret
))))
return
E_OUTOFMEMORY
;
ret
->
IInternetExplorerManager_iface
.
lpVtbl
=
&
InternetExplorerManager_vtbl
;
...
...
@@ -1057,19 +1057,19 @@ static HDDEDATA WINAPI dde_proc(UINT type, UINT uFmt, HCONV hConv, HSZ hsz1, HSZ
break
;
}
url
=
heap_
alloc
(
size
);
url
=
m
alloc
(
size
);
if
(
!
url
)
break
;
if
(
DdeGetData
(
data
,
(
BYTE
*
)
url
,
size
,
0
)
!=
size
)
{
ERR
(
"error during read
\n
"
);
heap_
free
(
url
);
free
(
url
);
break
;
}
ret
=
open_dde_url
(
url
);
heap_
free
(
url
);
free
(
url
);
return
ret
;
}
...
...
dlls/ieframe/intshcut.c
View file @
16fab1a4
...
...
@@ -97,7 +97,7 @@ static BOOL run_winemenubuilder( const WCHAR *args )
lstrcatW
(
app
,
menubuilder
);
len
=
(
lstrlenW
(
app
)
+
lstrlenW
(
args
)
+
1
)
*
sizeof
(
WCHAR
);
buffer
=
heap_
alloc
(
len
);
buffer
=
m
alloc
(
len
);
if
(
!
buffer
)
return
FALSE
;
...
...
@@ -113,7 +113,7 @@ static BOOL run_winemenubuilder( const WCHAR *args )
ret
=
CreateProcessW
(
app
,
buffer
,
NULL
,
NULL
,
FALSE
,
DETACHED_PROCESS
,
NULL
,
NULL
,
&
si
,
&
pi
);
Wow64RevertWow64FsRedirection
(
redir
);
heap_
free
(
buffer
);
free
(
buffer
);
if
(
ret
)
{
...
...
@@ -132,13 +132,13 @@ static BOOL StartLinkProcessor( LPCOLESTR szLink )
BOOL
ret
;
len
=
sizeof
(
szFormat
)
+
lstrlenW
(
szLink
)
*
sizeof
(
WCHAR
);
buffer
=
heap_
alloc
(
len
);
buffer
=
m
alloc
(
len
);
if
(
!
buffer
)
return
FALSE
;
swprintf
(
buffer
,
len
/
sizeof
(
WCHAR
),
szFormat
,
szLink
);
ret
=
run_winemenubuilder
(
buffer
);
heap_
free
(
buffer
);
free
(
buffer
);
return
ret
;
}
...
...
@@ -193,7 +193,7 @@ static ULONG Unknown_Release(InternetShortcut *This)
CoTaskMemFree
(
This
->
url
);
CoTaskMemFree
(
This
->
currentFile
);
IPropertySetStorage_Release
(
This
->
property_set_storage
);
heap_
free
(
This
);
free
(
This
);
unlock_module
();
}
return
count
;
...
...
@@ -374,13 +374,13 @@ static HRESULT WINAPI UniformResourceLocatorA_InvokeCommand(IUniformResourceLoca
wideCommandInfo
.
hwndParent
=
pCommandInfo
->
hwndParent
;
len
=
MultiByteToWideChar
(
CP_ACP
,
0
,
pCommandInfo
->
pcszVerb
,
-
1
,
NULL
,
0
);
wideVerb
=
heap_
alloc
(
len
*
sizeof
(
WCHAR
));
wideVerb
=
m
alloc
(
len
*
sizeof
(
WCHAR
));
MultiByteToWideChar
(
CP_ACP
,
0
,
pCommandInfo
->
pcszVerb
,
-
1
,
wideVerb
,
len
);
wideCommandInfo
.
pcszVerb
=
wideVerb
;
res
=
UniformResourceLocatorW_InvokeCommand
(
&
This
->
IUniformResourceLocatorW_iface
,
&
wideCommandInfo
);
heap_
free
(
wideVerb
);
free
(
wideVerb
);
return
res
;
}
...
...
@@ -565,7 +565,7 @@ static HRESULT WINAPI PersistFile_Save(IPersistFile *pFile, LPCOLESTR pszFileNam
* An ASCII (probably UTF8?) value in "URL=..."
*/
len
=
WideCharToMultiByte
(
CP_UTF8
,
0
,
This
->
url
,
-
1
,
NULL
,
0
,
0
,
0
);
url
=
heap_
alloc
(
len
);
url
=
m
alloc
(
len
);
if
(
url
!=
NULL
)
{
HANDLE
file
;
...
...
@@ -607,14 +607,14 @@ static HRESULT WINAPI PersistFile_Save(IPersistFile *pFile, LPCOLESTR pszFileNam
{
char
indexString
[
50
];
len
=
WideCharToMultiByte
(
CP_UTF8
,
0
,
pvread
[
0
].
pwszVal
,
-
1
,
NULL
,
0
,
0
,
0
);
iconfile
=
heap_
alloc
(
len
);
iconfile
=
m
alloc
(
len
);
if
(
iconfile
!=
NULL
)
{
WideCharToMultiByte
(
CP_UTF8
,
0
,
pvread
[
0
].
pwszVal
,
-
1
,
iconfile
,
len
,
0
,
0
);
WriteFile
(
file
,
str_ICONFILE
,
lstrlenA
(
str_ICONFILE
),
&
bytesWritten
,
NULL
);
WriteFile
(
file
,
iconfile
,
lstrlenA
(
iconfile
),
&
bytesWritten
,
NULL
);
WriteFile
(
file
,
str_eol
,
lstrlenA
(
str_eol
),
&
bytesWritten
,
NULL
);
heap_
free
(
iconfile
);
free
(
iconfile
);
}
sprintf
(
indexString
,
"ICONINDEX=%d"
,
pvread
[
1
].
iVal
);
...
...
@@ -642,7 +642,7 @@ static HRESULT WINAPI PersistFile_Save(IPersistFile *pFile, LPCOLESTR pszFileNam
}
else
hr
=
E_FAIL
;
heap_
free
(
url
);
free
(
url
);
}
else
hr
=
E_OUTOFMEMORY
;
...
...
@@ -793,7 +793,7 @@ static InternetShortcut *create_shortcut(void)
{
InternetShortcut
*
newshortcut
;
newshortcut
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
InternetShortcut
));
newshortcut
=
calloc
(
1
,
sizeof
(
InternetShortcut
));
if
(
newshortcut
)
{
HRESULT
hr
;
...
...
@@ -809,7 +809,7 @@ static InternetShortcut *create_shortcut(void)
if
(
FAILED
(
hr
))
{
TRACE
(
"Failed to create the storage object needed for the shortcut.
\n
"
);
heap_
free
(
newshortcut
);
free
(
newshortcut
);
return
NULL
;
}
...
...
@@ -818,7 +818,7 @@ static InternetShortcut *create_shortcut(void)
{
TRACE
(
"Failed to create the property object needed for the shortcut.
\n
"
);
IPropertySetStorage_Release
(
newshortcut
->
property_set_storage
);
heap_
free
(
newshortcut
);
free
(
newshortcut
);
return
NULL
;
}
IPropertyStorage_Release
(
dummy
);
...
...
@@ -864,7 +864,7 @@ void WINAPI OpenURL(HWND hWnd, HINSTANCE hInst, LPCSTR lpcstrUrl, int nShowCmd)
return
;
len
=
MultiByteToWideChar
(
CP_ACP
,
0
,
lpcstrUrl
,
-
1
,
NULL
,
0
);
urlfilepath
=
heap_
alloc
(
len
*
sizeof
(
WCHAR
));
urlfilepath
=
m
alloc
(
len
*
sizeof
(
WCHAR
));
MultiByteToWideChar
(
CP_ACP
,
0
,
lpcstrUrl
,
-
1
,
urlfilepath
,
len
);
if
(
SUCCEEDED
(
IPersistFile_Load
(
&
shortcut
->
IPersistFile_iface
,
urlfilepath
,
0
)))
{
...
...
@@ -879,6 +879,6 @@ void WINAPI OpenURL(HWND hWnd, HINSTANCE hInst, LPCSTR lpcstrUrl, int nShowCmd)
TRACE
(
"failed to open URL: %s
\n
"
,
debugstr_a
(
lpcstrUrl
));
}
heap_
free
(
urlfilepath
);
free
(
urlfilepath
);
Unknown_Release
(
shortcut
);
}
dlls/ieframe/navigate.c
View file @
16fab1a4
...
...
@@ -132,14 +132,14 @@ HRESULT set_dochost_url(DocHost *This, const WCHAR *url)
WCHAR
*
new_url
;
if
(
url
)
{
new_url
=
heap_strdupW
(
url
);
new_url
=
wcsdup
(
url
);
if
(
!
new_url
)
return
E_OUTOFMEMORY
;
}
else
{
new_url
=
NULL
;
}
heap_
free
(
This
->
url
);
free
(
This
->
url
);
This
->
url
=
new_url
;
This
->
container_vtbl
->
set_url
(
This
,
This
->
url
);
...
...
@@ -215,7 +215,7 @@ static ULONG WINAPI BindStatusCallback_Release(IBindStatusCallback *iface)
GlobalFree
(
This
->
post_data
);
SysFreeString
(
This
->
headers
);
SysFreeString
(
This
->
url
);
heap_
free
(
This
);
free
(
This
);
}
return
ref
;
...
...
@@ -546,7 +546,7 @@ static const IHttpSecurityVtbl HttpSecurityVtbl = {
static
BindStatusCallback
*
create_callback
(
DocHost
*
doc_host
,
LPCWSTR
url
,
PBYTE
post_data
,
ULONG
post_data_len
,
LPCWSTR
headers
)
{
BindStatusCallback
*
ret
=
heap_
alloc
(
sizeof
(
BindStatusCallback
));
BindStatusCallback
*
ret
=
m
alloc
(
sizeof
(
BindStatusCallback
));
ret
->
IBindStatusCallback_iface
.
lpVtbl
=
&
BindStatusCallbackVtbl
;
ret
->
IHttpNegotiate_iface
.
lpVtbl
=
&
HttpNegotiateVtbl
;
...
...
@@ -780,7 +780,7 @@ static void doc_navigate_task_destr(task_header_t *t)
SysFreeString
(
task
->
headers
);
if
(
task
->
post_data
)
SafeArrayDestroy
(
task
->
post_data
);
heap_
free
(
task
);
free
(
task
);
}
static
void
doc_navigate_proc
(
DocHost
*
This
,
task_header_t
*
t
)
...
...
@@ -819,7 +819,7 @@ static HRESULT async_doc_navigate(DocHost *This, LPCWSTR url, LPCWSTR headers, P
TRACE
(
"%s
\n
"
,
debugstr_w
(
url
));
task
=
heap_alloc_zero
(
sizeof
(
*
task
));
task
=
calloc
(
1
,
sizeof
(
*
task
));
if
(
!
task
)
return
E_OUTOFMEMORY
;
...
...
@@ -920,7 +920,7 @@ static void navigate_bsc_task_destr(task_header_t *t)
task_navigate_bsc_t
*
task
=
(
task_navigate_bsc_t
*
)
t
;
IBindStatusCallback_Release
(
&
task
->
bsc
->
IBindStatusCallback_iface
);
heap_
free
(
task
);
free
(
task
);
}
static
void
navigate_bsc_proc
(
DocHost
*
This
,
task_header_t
*
t
)
...
...
@@ -993,7 +993,7 @@ HRESULT navigate_url(DocHost *This, LPCWSTR url, const VARIANT *Flags,
}
else
{
task_navigate_bsc_t
*
task
;
task
=
heap_
alloc
(
sizeof
(
*
task
));
task
=
m
alloc
(
sizeof
(
*
task
));
task
->
bsc
=
create_callback
(
This
,
url
,
post_data
,
post_data_len
,
headers
);
push_dochost_task
(
This
,
&
task
->
header
,
navigate_bsc_proc
,
navigate_bsc_task_destr
,
This
->
url
==
NULL
);
}
...
...
dlls/ieframe/oleobject.c
View file @
16fab1a4
...
...
@@ -374,7 +374,7 @@ static ULONG WINAPI EnumOLEVERB_Release(IEnumOLEVERB *iface)
TRACE
(
"(%p) ref=%ld
\n
"
,
This
,
ref
);
if
(
!
ref
)
heap_
free
(
This
);
free
(
This
);
return
ref
;
}
...
...
@@ -718,7 +718,7 @@ static HRESULT WINAPI OleObject_EnumVerbs(IOleObject *iface, IEnumOLEVERB **ppEn
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
ppEnumOleVerb
);
ret
=
heap_
alloc
(
sizeof
(
*
ret
));
ret
=
m
alloc
(
sizeof
(
*
ret
));
if
(
!
ret
)
return
E_OUTOFMEMORY
;
...
...
dlls/ieframe/shellbrowser.c
View file @
16fab1a4
...
...
@@ -83,7 +83,7 @@ static ULONG WINAPI ShellBrowser_Release(IShellBrowser* iface)
if
(
!
ref
)
{
assert
(
!
This
->
doc_host
);
heap_
free
(
This
);
free
(
This
);
}
return
ref
;
...
...
@@ -922,7 +922,7 @@ HRESULT create_browser_service(DocHost *doc_host, ShellBrowser **ret)
{
ShellBrowser
*
sb
;
sb
=
heap_
alloc
(
sizeof
(
ShellBrowser
));
sb
=
m
alloc
(
sizeof
(
ShellBrowser
));
if
(
!
sb
)
return
E_OUTOFMEMORY
;
...
...
dlls/ieframe/shelluihelper.c
View file @
16fab1a4
...
...
@@ -76,7 +76,7 @@ static ULONG WINAPI ShellUIHelper2_Release(IShellUIHelper2 *iface)
TRACE
(
"(%p) ref=%ld
\n
"
,
This
,
ref
);
if
(
!
ref
)
heap_
free
(
This
);
free
(
This
);
return
ref
;
}
...
...
@@ -370,7 +370,7 @@ HRESULT create_shell_ui_helper(IShellUIHelper2 **_ret)
{
ShellUIHelper
*
ret
;
ret
=
heap_
alloc
(
sizeof
(
*
ret
));
ret
=
m
alloc
(
sizeof
(
*
ret
));
if
(
!
ret
)
return
E_OUTOFMEMORY
;
...
...
dlls/ieframe/webbrowser.c
View file @
16fab1a4
...
...
@@ -180,7 +180,7 @@ static ULONG WINAPI WebBrowser_Release(IUnknown *iface)
WebBrowser_OleObject_Destroy
(
This
);
heap_
free
(
This
);
free
(
This
);
unlock_module
();
}
...
...
@@ -1287,7 +1287,7 @@ static HRESULT create_webbrowser(int version, IUnknown *outer, REFIID riid, void
if
(
outer
&&
!
IsEqualIID
(
riid
,
&
IID_IUnknown
))
return
CLASS_E_NOAGGREGATION
;
ret
=
heap_alloc_zero
(
sizeof
(
WebBrowser
));
ret
=
calloc
(
1
,
sizeof
(
WebBrowser
));
ret
->
IUnknown_inner
.
lpVtbl
=
&
internal_unk_vtbl
;
ret
->
IWebBrowser2_iface
.
lpVtbl
=
&
WebBrowser2Vtbl
;
...
...
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