Abort() private method

private Abort ( ) : void
return void
Ejemplo n.º 1
0
 internal void Abort()
 {
     if (_connection != null)
     {
         _connection.Abort();
     }
 }
Ejemplo n.º 2
0
        internal void GetConnection(string host, int port)
        {
            try
            {
                lock (this)
                {
                    _connection = new SmtpConnection(this, _client, _credentials, _authenticationModules);
                    if (_shouldAbort)
                    {
                        _connection.Abort();
                    }
                    _shouldAbort = false;
                }

                if (NetEventSource.IsEnabled)
                {
                    NetEventSource.Associate(this, _connection);
                }

                if (EnableSsl)
                {
                    _connection.EnableSsl          = true;
                    _connection.ClientCertificates = ClientCertificates;
                }

                _connection.GetConnection(host, port);
            }
            finally { }
        }
Ejemplo n.º 3
0
 internal void Abort()
 {
     lock (this)
     {
         if (_connection != null)
         {
             _connection.Abort();
         }
         else
         {
             _shouldAbort = true;
         }
     }
 }