// This check if the call-site on the TP is in our own AD // It also handles the special case where the TP is on // a well-known object and we cannot do stack-blting internal bool IsOKToStackBlt(IMethodMessage mcMsg, Object server) { bool bOK = false; Message msg = mcMsg as Message; if (null != msg) { IInternalMessage iiMsg = (IInternalMessage)msg; // If there is a frame in the message we can always // Blt it (provided it is not a proxy to a well-known // object in our own appDomain)! // The GetThisPtr == server test allows for people to wrap // our proxy with their own interception .. in that case // we should not blt the stack. if (msg.GetFramePtr() != IntPtr.Zero && msg.GetThisPtr() == server && (iiMsg.IdentityObject == null || (iiMsg.IdentityObject != null && iiMsg.IdentityObject == iiMsg.ServerIdentityObject ) ) ) { bOK = true; } } return(bOK); }
internal bool IsOKToStackBlt(IMethodMessage mcMsg, object server) { bool result = false; Message message = mcMsg as Message; if (message != null) { IInternalMessage internalMessage = message; if (message.GetFramePtr() != IntPtr.Zero && message.GetThisPtr() == server && (internalMessage.IdentityObject == null || (internalMessage.IdentityObject != null && internalMessage.IdentityObject == internalMessage.ServerIdentityObject))) { result = true; } } return(result); }
internal bool IsOKToStackBlt(IMethodMessage mcMsg, object server) { bool flag = false; Message message = mcMsg as Message; if (message == null) { return(flag); } IInternalMessage message2 = message; if ((!(message.GetFramePtr() != IntPtr.Zero) || (message.GetThisPtr() != server)) || ((message2.IdentityObject != null) && ((message2.IdentityObject == null) || (message2.IdentityObject != message2.ServerIdentityObject)))) { return(flag); } return(true); }