} // Write protected override void Dispose(bool disposing) { try { if (disposing) { _port.Dispose(); } } finally { base.Dispose(disposing); } }
public void ReleaseConnection(IpcPort port) { string name = port.Name; PortConnection connection = (PortConnection) _connections[name]; if (port.Cacheable && ((connection == null) || connection.Port.IsDisposed)) { lock (_connections) { _connections[name] = new PortConnection(port); return; } } port.Dispose(); }
public void ReleaseConnection(IpcPort port) { string name = port.Name; PortConnection connection = (PortConnection)_connections[name]; if (port.Cacheable && ((connection == null) || connection.Port.IsDisposed)) { lock (_connections) { _connections[name] = new PortConnection(port); return; } } port.Dispose(); }
} // GetSocket public void ReleaseConnection(IpcPort port) { string portName = port.Name; PortConnection connection = (PortConnection)_connections[portName]; if (port.Cacheable && (connection == null || connection.Port.IsDisposed)) { lock (_connections) { _connections[portName] = new PortConnection(port); } } else { // there should have been a connection, so let's just close // this socket. port.Dispose(); } } // ReleasePort
public void StopListening(Object data) { InternalRemotingServices.RemotingTrace("IpcChannel.StopListening"); _bListening = false; _port.Dispose(); } // StopListening
} // GetSocket public void ReleaseConnection(IpcPort port) { string portName = port.Name; PortConnection connection = (PortConnection)_connections[portName]; if (port.Cacheable && (connection == null || connection.Port.IsDisposed)) { lock(_connections) { _connections[portName] = new PortConnection(port); } } else { // there should have been a connection, so let's just close // this socket. port.Dispose(); } } // ReleasePort