diff options
author | danmosemsft <danmose@microsoft.com> | 2017-02-12 12:08:12 -0800 |
---|---|---|
committer | danmosemsft <danmose@microsoft.com> | 2017-02-12 16:58:48 -0800 |
commit | 2f50fd27bfde5f2bc32c081e6a2196f92fc03992 (patch) | |
tree | e05ee9d8a633653db4da44dd19042470b56d4202 /src/vm/clrprivbinderutil.cpp | |
parent | f2704e6d0b45d37a638ef320a908ff0e3b23f0b5 (diff) | |
download | coreclr-2f50fd27bfde5f2bc32c081e6a2196f92fc03992.tar.gz coreclr-2f50fd27bfde5f2bc32c081e6a2196f92fc03992.tar.bz2 coreclr-2f50fd27bfde5f2bc32c081e6a2196f92fc03992.zip |
Remove never defined FEATURE_APPX_BINDER
Diffstat (limited to 'src/vm/clrprivbinderutil.cpp')
-rw-r--r-- | src/vm/clrprivbinderutil.cpp | 97 |
1 files changed, 0 insertions, 97 deletions
diff --git a/src/vm/clrprivbinderutil.cpp b/src/vm/clrprivbinderutil.cpp index b6871123d9..46d50f1552 100644 --- a/src/vm/clrprivbinderutil.cpp +++ b/src/vm/clrprivbinderutil.cpp @@ -731,101 +731,4 @@ namespace CLRPrivBinderUtil //////////////////////////////////////////////////////////////////////////////////////////////////// ///// ----------------------------- Direct calls to VM ------------------------------------------- //////////////////////////////////////////////////////////////////////////////////////////////////// -#if defined(FEATURE_APPX_BINDER) - ICLRPrivAssembly* RaiseAssemblyResolveEvent(IAssemblyName *pAssemblyName, ICLRPrivAssembly* pRequestingAssembly) - { - CONTRACT(ICLRPrivAssembly*) - { - THROWS; - GC_TRIGGERS; - MODE_ANY; - PRECONDITION(AppX::IsAppXProcess()); - PRECONDITION(AppDomain::GetCurrentDomain()->IsDefaultDomain()); - POSTCONDITION(CheckPointer(RETVAL, NULL_OK)); - INJECT_FAULT(COMPlusThrowOM();); - } - CONTRACT_END; - - BinderMethodID methodId; - - methodId = METHOD__APP_DOMAIN__ON_ASSEMBLY_RESOLVE; // post-bind execution event (the classic V1.0 event) - - // Elevate threads allowed loading level. This allows the host to load an assembly even in a restricted - // condition. Note, however, that this exposes us to possible recursion failures, if the host tries to - // load the assemblies currently being loaded. (Such cases would then throw an exception.) - - OVERRIDE_LOAD_LEVEL_LIMIT(FILE_ACTIVE); - OVERRIDE_TYPE_LOAD_LEVEL_LIMIT(CLASS_LOADED); - - DomainAssembly* pDomainAssembly = AppDomain::GetCurrentDomain()->FindAssembly(pRequestingAssembly); - - GCX_COOP(); - - Assembly* pAssembly = NULL; - - struct _gc { - OBJECTREF AppDomainRef; - OBJECTREF AssemblyRef; - STRINGREF str; - } gc; - ZeroMemory(&gc, sizeof(gc)); - - SString ssAssemblyName; - FusionBind::GetAssemblyNameDisplayName(pAssemblyName, ssAssemblyName); - - GCPROTECT_BEGIN(gc); - if ((gc.AppDomainRef = GetAppDomain()->GetRawExposedObject()) != NULL) - { - gc.AssemblyRef = pDomainAssembly->GetExposedAssemblyObject(); - - MethodDescCallSite onAssemblyResolve(methodId, &gc.AppDomainRef); - - gc.str = StringObject::NewString(ssAssemblyName.GetUnicode()); - ARG_SLOT args[3] = { - ObjToArgSlot(gc.AppDomainRef), - ObjToArgSlot(gc.AssemblyRef), - ObjToArgSlot(gc.str) - }; - ASSEMBLYREF ResultingAssemblyRef = (ASSEMBLYREF) onAssemblyResolve.Call_RetOBJECTREF(args); - if (ResultingAssemblyRef != NULL) - { - pAssembly = ResultingAssemblyRef->GetAssembly(); - } - } - GCPROTECT_END(); - - if (pAssembly != NULL) - { - if (pAssembly->IsIntrospectionOnly()) - { - // Cannot return an introspection assembly from an execution callback or vice-versa - COMPlusThrow(kFileLoadException, IDS_CLASSLOAD_ASSEMBLY_RESOLVE_RETURNED_INTROSPECTION ); - } - if (pAssembly->IsCollectible()) - { - COMPlusThrow(kNotSupportedException, W("NotSupported_CollectibleAssemblyResolve")); - } - - // Check that the public key token matches the one specified in the spec - // MatchPublicKeys throws as appropriate. - - StackScratchBuffer ssBuffer; - AssemblySpec spec; - IfFailThrow(spec.Init(ssAssemblyName.GetUTF8(ssBuffer))); - spec.MatchPublicKeys(pAssembly); - - } - - if (pAssembly == nullptr) - ThrowHR(COR_E_FILENOTFOUND); - - RETURN pAssembly->GetManifestFile()->GetHostAssembly(); - } - - BOOL CompareHostBinderSpecs(AssemblySpec * a1, AssemblySpec * a2) - { - WRAPPER_NO_CONTRACT; - return a1->CompareEx(a2, AssemblySpec::ASC_Default); - } -#endif // FEATURE_APPX } // namespace CLRPrivBinderUtil |