コード例 #1
0
ファイル: TcpServer.cpp プロジェクト: richardor/mediasoup
	void TcpServer::UserOnNewTcpConnection(::TcpConnection* connection)
	{
		MS_TRACE();

		// Allow just MaxTcpConnectionsPerServer.
		if (GetNumConnections() > MaxTcpConnectionsPerServer)
			connection->Destroy();
	}
コード例 #2
0
ファイル: HTTP_s.cpp プロジェクト: Omgan/RealFTP.net
/********************************
Destructor
*********************************/
CUT_HTTPServer::~CUT_HTTPServer(){

    // Shut down the accept thread
    StopAccept();

	// Wait for threads to shutdown
    m_bShutDown = TRUE;
    while(GetNumConnections())
	    Sleep(50);
}
コード例 #3
0
ファイル: smtp_s.cpp プロジェクト: Omgan/RealFTP.net
/***************************************
Destructor
****************************************/
CUT_SMTPServer::~CUT_SMTPServer(){
    m_bShutDown = TRUE;
    while(GetNumConnections())
	    Sleep(50);

}