mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-06 10:20:21 +00:00
riched20: Use regular allocation helpers for text services objects.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Huw Davies <huw@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
1d5c9defb1
commit
2064c206c0
|
@ -93,7 +93,7 @@ struct host *host_create( HWND hwnd, CREATESTRUCTW *cs, BOOL emulate_10 )
|
|||
{
|
||||
struct host *texthost;
|
||||
|
||||
texthost = CoTaskMemAlloc(sizeof(*texthost));
|
||||
texthost = heap_alloc(sizeof(*texthost));
|
||||
if (!texthost) return NULL;
|
||||
|
||||
texthost->ITextHost_iface.lpVtbl = &textHostVtbl;
|
||||
|
@ -158,7 +158,7 @@ static ULONG WINAPI ITextHostImpl_Release( ITextHost2 *iface )
|
|||
{
|
||||
SetWindowLongPtrW( host->window, 0, 0 );
|
||||
ITextServices_Release( host->text_srv );
|
||||
CoTaskMemFree( host );
|
||||
heap_free( host );
|
||||
}
|
||||
return ref;
|
||||
}
|
||||
|
|
|
@ -81,7 +81,7 @@ static ULONG WINAPI ITextServicesImpl_Release(IUnknown *iface)
|
|||
{
|
||||
richole_release_children( services );
|
||||
ME_DestroyEditor( services->editor );
|
||||
CoTaskMemFree( services );
|
||||
heap_free( services );
|
||||
}
|
||||
return ref;
|
||||
}
|
||||
|
@ -580,7 +580,7 @@ HRESULT create_text_services( IUnknown *outer, ITextHost *text_host, IUnknown **
|
|||
TRACE( "%p %p --> %p\n", outer, text_host, unk );
|
||||
if (text_host == NULL) return E_POINTER;
|
||||
|
||||
services = CoTaskMemAlloc( sizeof(*services) );
|
||||
services = heap_alloc( sizeof(*services) );
|
||||
if (services == NULL) return E_OUTOFMEMORY;
|
||||
services->ref = 1;
|
||||
services->IUnknown_inner.lpVtbl = &textservices_inner_vtbl;
|
||||
|
|
Loading…
Reference in a new issue