MCPcopy Create free account
hub / github.com/MaxBelkov/visualsyslog / TcpAccept

Function TcpAccept

source/tcpcon.cpp:115–130  ·  view source on GitHub ↗

---------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

113}
114//---------------------------------------------------------------------------
115void TcpAccept(void)
116{
117 // Have new TCP connection ?
118 MSocket * p = tcp->GetClient(1); // 1 msec
119 if( p )
120 {
121 // yes
122 TcpAddConnection(p);
123 }
124 else
125 {
126 if( tcp->errcode )
127 WriteToLogError("ERROR\tTCP connection: %s code=%ld",
128 tcp->GetErrorMessageEng().c_str(), tcp->errcode);
129 }
130}
131//---------------------------------------------------------------------------
132void TcpAddConnection(MSocket * p)
133{

Callers 1

NetTimerTimerMethod · 0.85

Calls 4

TcpAddConnectionFunction · 0.85
WriteToLogErrorFunction · 0.85
GetClientMethod · 0.80
GetErrorMessageEngMethod · 0.45

Tested by

no test coverage detected