combase: Move CoGetCallContext().
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
7a347c20dc
commit
06a90f7f11
|
@ -1387,3 +1387,22 @@ void WINAPI DECLSPEC_HOTPATCH CoFreeUnusedLibraries(void)
|
||||||
{
|
{
|
||||||
CoFreeUnusedLibrariesEx(INFINITE, 0);
|
CoFreeUnusedLibrariesEx(INFINITE, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* CoGetCallContext (combase.@)
|
||||||
|
*/
|
||||||
|
HRESULT WINAPI CoGetCallContext(REFIID riid, void **obj)
|
||||||
|
{
|
||||||
|
struct tlsdata *tlsdata;
|
||||||
|
HRESULT hr;
|
||||||
|
|
||||||
|
TRACE("%s, %p\n", debugstr_guid(riid), obj);
|
||||||
|
|
||||||
|
if (FAILED(hr = com_get_tlsdata(&tlsdata)))
|
||||||
|
return hr;
|
||||||
|
|
||||||
|
if (!tlsdata->call_state)
|
||||||
|
return RPC_E_CALL_COMPLETE;
|
||||||
|
|
||||||
|
return IUnknown_QueryInterface(tlsdata->call_state, riid, obj);
|
||||||
|
}
|
||||||
|
|
|
@ -97,7 +97,7 @@
|
||||||
@ stdcall CoGetActivationState(int128 long ptr)
|
@ stdcall CoGetActivationState(int128 long ptr)
|
||||||
@ stub CoGetApartmentID
|
@ stub CoGetApartmentID
|
||||||
@ stdcall CoGetApartmentType(ptr ptr) ole32.CoGetApartmentType
|
@ stdcall CoGetApartmentType(ptr ptr) ole32.CoGetApartmentType
|
||||||
@ stdcall CoGetCallContext(ptr ptr) ole32.CoGetCallContext
|
@ stdcall CoGetCallContext(ptr ptr)
|
||||||
@ stdcall CoGetCallState(long ptr)
|
@ stdcall CoGetCallState(long ptr)
|
||||||
@ stdcall CoGetCallerTID(ptr) ole32.CoGetCallerTID
|
@ stdcall CoGetCallerTID(ptr) ole32.CoGetCallerTID
|
||||||
@ stub CoGetCancelObject
|
@ stub CoGetCancelObject
|
||||||
|
|
|
@ -3458,35 +3458,6 @@ HRESULT WINAPI CoAllowSetForegroundWindow(IUnknown *pUnk, void *pvReserved)
|
||||||
return S_OK;
|
return S_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* CoGetCallContext [OLE32.@]
|
|
||||||
*
|
|
||||||
* Gets the context of the currently executing server call in the current
|
|
||||||
* thread.
|
|
||||||
*
|
|
||||||
* PARAMS
|
|
||||||
* riid [I] Context interface to return.
|
|
||||||
* ppv [O] Pointer to memory that will receive the context on return.
|
|
||||||
*
|
|
||||||
* RETURNS
|
|
||||||
* Success: S_OK.
|
|
||||||
* Failure: HRESULT code.
|
|
||||||
*/
|
|
||||||
HRESULT WINAPI CoGetCallContext(REFIID riid, void **ppv)
|
|
||||||
{
|
|
||||||
struct oletls *info = COM_CurrentInfo();
|
|
||||||
|
|
||||||
TRACE("(%s, %p)\n", debugstr_guid(riid), ppv);
|
|
||||||
|
|
||||||
if (!info)
|
|
||||||
return E_OUTOFMEMORY;
|
|
||||||
|
|
||||||
if (!info->call_state)
|
|
||||||
return RPC_E_CALL_COMPLETE;
|
|
||||||
|
|
||||||
return IUnknown_QueryInterface(info->call_state, riid, ppv);
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* CoSwitchCallContext [OLE32.@]
|
* CoSwitchCallContext [OLE32.@]
|
||||||
*
|
*
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
@ stdcall CoFreeUnusedLibrariesEx(long long)
|
@ stdcall CoFreeUnusedLibrariesEx(long long)
|
||||||
@ stdcall CoGetActivationState(int128 long ptr) combase.CoGetActivationState
|
@ stdcall CoGetActivationState(int128 long ptr) combase.CoGetActivationState
|
||||||
@ stdcall CoGetApartmentType(ptr ptr)
|
@ stdcall CoGetApartmentType(ptr ptr)
|
||||||
@ stdcall CoGetCallContext(ptr ptr)
|
@ stdcall CoGetCallContext(ptr ptr) combase.CoGetCallContext
|
||||||
@ stdcall CoGetCallState(long ptr) combase.CoGetCallState
|
@ stdcall CoGetCallState(long ptr) combase.CoGetCallState
|
||||||
@ stdcall CoGetCallerTID(ptr)
|
@ stdcall CoGetCallerTID(ptr)
|
||||||
@ stdcall CoGetClassObject(ptr long ptr ptr ptr)
|
@ stdcall CoGetClassObject(ptr long ptr ptr ptr)
|
||||||
|
|
Loading…
Reference in New Issue