private object[] WriteMethodReturn(IMethodReturnMessage mrm) { object returnValue = mrm.ReturnValue; object[] args = mrm.Args; Exception exception = mrm.Exception; object[] properties = (object[])null; ReturnMessage returnMessage = mrm as ReturnMessage; if (returnMessage == null || returnMessage.HasProperties()) { properties = ObjectWriter.StoreUserPropertiesForMethodMessage((IMethodMessage)mrm); } LogicalCallContext logicalCallContext = mrm.LogicalCallContext; object callContext = logicalCallContext != null ? (!logicalCallContext.HasInfo ? (object)logicalCallContext.RemotingData.LogicalCallID : (object)logicalCallContext) : (object)null; return(this.serWriter.WriteReturnArray(returnValue, args, exception, callContext, properties)); }