mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-08-17 18:40:49 -04:00
Limit the concurrent connection attempts in Windows XP. Its's only a hack.
Problem: RetroShare connects to all ssl's at once. In Windows XP there is a build-in connection limit of concurrent incomplete connections. Quote: "The TCP/IP stack in Windows XP with Service Pack 2 (SP2) installed limits the number of concurrent, incomplete outbound TCP connection attempts. When the limit is reached, subsequent connection attempts are put in a queue and resolved at a fixed rate so that there are only a limited number of connections in the incomplete state." This results in a high usage of the nonepaged pool and when it runs over the limit it results in the following error in the system log: German: "TCP/IP hat das Sicherheitslimit erreicht, das für die Anzahl gleichzeitiger TCP-Verbindungsversuche festgelegt wurde." English: "TCP/IP has reached the security limit imposed on the number of concurrent (incomplete) TCP connect attempts." After a longer runtime of RetroShare and a very high usage of the nonepaged pool all connections of all running programs are lost and no new connections can be made. At the end it can cause a blue screen. git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3631 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
c134b5f605
commit
f4bbd3e933
6 changed files with 188 additions and 4 deletions
|
@ -64,10 +64,24 @@ int load_config();
|
|||
/*************** pqiMonitor callback ***********************/
|
||||
virtual void statusChange(const std::list<pqipeer> &plist);
|
||||
|
||||
#ifdef WINDOWS_SYS
|
||||
///////////////////////////////////////////////////////////
|
||||
// hack for too many connections
|
||||
virtual void statusChanged();
|
||||
///////////////////////////////////////////////////////////
|
||||
#endif
|
||||
|
||||
/******************* Peer Control **************************/
|
||||
virtual int addPeer(std::string id); /* can be overloaded for testing */
|
||||
int removePeer(std::string id);
|
||||
int connectPeer(std::string id);
|
||||
int connectPeer(std::string id
|
||||
#ifdef WINDOWS_SYS
|
||||
///////////////////////////////////////////////////////////
|
||||
// hack for too many connections
|
||||
, bool bConnect = false
|
||||
///////////////////////////////////////////////////////////
|
||||
#endif
|
||||
);
|
||||
|
||||
/* Work-around to dodgy pointer stuff */
|
||||
int tagHeartbeatRecvd(std::string id);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue