private Cap AcceptCap(object sender, out string uri)
{
uri = null;
if (_disposed) return null;
if (this.State == ManagerState.Stop) return null;
Socket socket = null;
try
{
string base32Address;
socket = _samManager.Accept(out base32Address);
uri = string.Format("i2p:{0}", base32Address);
}
catch (SamException)
{
if (socket != null) socket.Dispose();
return null;
}
return new SocketCap(socket);
}