我为一些自定义要求构建了IL重写器。它所做的全是
I have built the IL Rewriter for some custom requirement. All it does is
样本Windows窗体应用程序的一切正常。但是,对于Web应用程序,结语&序幕正在被正确注入。但是,当它被调用时,它会抛出错误 -
Everything works fine with sample Windows form application. However, for the web application, epilogue & prologue are getting injected properly. But, when it gets called, it throws below error -
System.IO.FileLoadException: Loading this assembly would produce a different grant set from other instances. (Exception from HRESULT: 0x80131401)
不知何故,新建的.Net DLL没有为WebApp加载虽然同样适用于Windows应用程序。
Somehow, the newly built .Net DLL is not getting loaded for WebApp, while the same is working fine for Windows App.
如果我禁用IL Rewrite,一切都正常工作。这意味着IL Rewrite导致错误。
If I disable IL Rewrite, everything works fine as expected. That means IL Rewrite is causing the error.
任何解决方案都将非常感激
Any solution would be much appreciated
Hitesh
推荐答案
Hi Hitesh Kesharia,
Hi Hitesh Kesharia,
对于您的问题,我发现您的问题已通过以下解决方案自行解决。
For your question, I found that your question has been solved by yourself with the solution below.
更改
COMPLUS_LoaderOptimization到
1
最好的问候,
Wendy
更多推荐
IL Rewrite无法加载.Net DLL
发布评论