private static LogicalCallContext GetLogicalCallContext() { lock (syncObject) { if (singletonCallContext == null) { CallContextProxy proxy = new CallContextProxy(typeof(IDisposable)); ((IDisposable)proxy.GetTransparentProxy()).Dispose(); singletonCallContext = proxy.CallContext; } return(singletonCallContext.Clone() as LogicalCallContext); } }
static LogicalCallContext GetLogicalCallContext() { lock (syncObject) { if (singletonCallContext == null) { CallContextProxy contextProxy = new CallContextProxy(typeof(IDisposable)); IDisposable disposable = (IDisposable)contextProxy.GetTransparentProxy(); disposable.Dispose(); singletonCallContext = contextProxy.CallContext; } return(singletonCallContext.Clone() as LogicalCallContext); } }
static LogicalCallContext GetLogicalCallContext() { lock (syncObject) { if (singletonCallContext == null) { CallContextProxy contextProxy = new CallContextProxy(typeof(IDisposable)); IDisposable disposable = (IDisposable)contextProxy.GetTransparentProxy(); disposable.Dispose(); singletonCallContext = contextProxy.CallContext; } return singletonCallContext.Clone() as LogicalCallContext; } }
private static LogicalCallContext GetLogicalCallContext() { lock (syncObject) { if (singletonCallContext == null) { CallContextProxy proxy = new CallContextProxy(typeof(IDisposable)); ((IDisposable) proxy.GetTransparentProxy()).Dispose(); singletonCallContext = proxy.CallContext; } return (singletonCallContext.Clone() as LogicalCallContext); } }