Exemplo n.º 1
0
        //
        // IncrementConnection
        //
        // Call to indicate that we now are starting a new
        //  connection within this service point
        //

        internal void IncrementConnection()
        {
            GlobalLog.Print("IncrementConnection #" + m_CurrentConnections.ToString() + "  #" + this.GetHashCode().ToString());
            // we need these to be atomic operations
            lock (this) {
                m_CurrentConnections++;
                if (m_CurrentConnections == 1)
                {
                    ServicePointManager.RemoveIdleServicePoint(this);
                }
            }
        }