summaryrefslogtreecommitdiff
path: root/src/vm/runtimecallablewrapper.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/vm/runtimecallablewrapper.cpp')
-rw-r--r--src/vm/runtimecallablewrapper.cpp44
1 files changed, 0 insertions, 44 deletions
diff --git a/src/vm/runtimecallablewrapper.cpp b/src/vm/runtimecallablewrapper.cpp
index 29999a7dad..dace892bf7 100644
--- a/src/vm/runtimecallablewrapper.cpp
+++ b/src/vm/runtimecallablewrapper.cpp
@@ -541,49 +541,9 @@ IClassFactory *ComClassFactory::GetIClassFactory()
StackSString ssServer;
if (FAILED(Clr::Util::Com::FindServerUsingCLSID(m_rclsid, ssServer)))
{
-#ifndef FEATURE_CORECLR
- // If there is no server entry, then that implies the CLSID could be implemented by CLR.DLL itself,
- // if the CLSID is one of the special ones implemented by the CLR. We need to check against the
- // specific list of CLSIDs here because CLR.DLL-implemented CLSIDs and managed class-implemented
- // CLSIDs look the same until you start interating the subkeys. For now, the set of CLSIDs implemented
- // by CLR.DLL is a short and tractable list, but at some point it might become worthwhile to move over
- // to the more generalized solution of looking for the entries that identify when the CLSID is
- // implemented by a managed type to avoid having to maintain the hardcoded list.
- if (IsClrHostedLegacyComObject(m_rclsid))
- {
- PDllGetClassObject pFN = NULL;
- hr = g_pCLRRuntime->GetProcAddress("DllGetClassObjectInternal", reinterpret_cast<void**>(&pFN));
-
- if (FAILED(hr))
- hr = g_pCLRRuntime->GetProcAddress("DllGetClassObject", reinterpret_cast<void**>(&pFN));
-
- if (SUCCEEDED(hr))
- hr = pFN(m_rclsid, IID_IClassFactory, (void**)&pClassFactory);
- }
-#endif
}
else
{
-#ifndef FEATURE_CORECLR
- // @CORESYSTODO: ?
-
- // There is a SxS DLL that implements this CLSID.
- // NOTE: It is standard practise for RCWs and P/Invokes to leak their module handles,
- // as there is no automated mechanism for the runtime to call CanUnloadDllNow.
- HMODULE hServer = NULL;
- if (SUCCEEDED(hr = g_pCLRRuntime->LoadLibrary(ssServer.GetUnicode(), &hServer)))
- {
- PDllGetClassObject pFN = reinterpret_cast<PDllGetClassObject>(GetProcAddress(hServer, "DllGetClassObject"));
- if (pFN != NULL)
- {
- hr = pFN(m_rclsid, IID_IClassFactory, (void**)&pClassFactory);
- }
- else
- {
- hr = HRESULT_FROM_GetLastError();
- }
- }
-#endif
}
}
#endif // FEATURE_CLASSIC_COMINTEROP
@@ -3107,12 +3067,10 @@ IUnknown *RCW::GetWellKnownInterface(REFIID riid)
// make sure it is on the right thread
IDispatch *RCW::GetIDispatch()
{
-#ifdef FEATURE_CORECLR
if (AppX::IsAppXProcess())
{
COMPlusThrow(kPlatformNotSupportedException, IDS_EE_ERROR_IDISPATCH);
}
-#endif // FEATURE_CORECLR
WRAPPER_NO_CONTRACT;
return (IDispatch *)GetWellKnownInterface(IID_IDispatch);
@@ -4574,9 +4532,7 @@ bool RCW::SupportsMngStdInterface(MethodTable *pItfMT)
if (pItfMT == MscorlibBinder::GetExistingClass(CLASS__IENUMERABLE))
{
SafeComHolder<IDispatch> pDisp = NULL;
-#ifdef FEATURE_CORECLR
if (!AppX::IsAppXProcess())
-#endif // FEATURE_CORECLR
{
// Get the IDispatch on the current thread.
pDisp = GetIDispatch();