git-svn-id: svn://db.shs.com.ru/pip@699 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5
This commit is contained in:
@@ -677,7 +677,7 @@ int PIEthernet::readDevice(void * read_to, int max_size) {
|
||||
s = accept(sock, (sockaddr * )&client_addr, &slen);
|
||||
if (s == -1) {
|
||||
//piCoutObj << "Can`t accept new connection, " << ethErrorString();
|
||||
msleep(1);
|
||||
msleep(PIP_MIN_MSLEEP);
|
||||
return -1;
|
||||
}
|
||||
rs = ethRecv(s, read_to, max_size);
|
||||
@@ -787,7 +787,7 @@ int PIEthernet::writeDevice(const void * data, int max_size) {
|
||||
//piCoutObj << "connect SingleTCP" << ip_s << ":" << port_s << "...";
|
||||
if (::connect(sock, (sockaddr * )&PRIVATE->addr_, sizeof(PRIVATE->addr_)) != 0) {
|
||||
//piCoutObj << "Can`t connect to " << ip_s << ":" << port_s << ", " << ethErrorString();
|
||||
msleep(1);
|
||||
msleep(PIP_MIN_MSLEEP);
|
||||
return -1;
|
||||
}
|
||||
//piCoutObj << "ok, write SingleTCP" << int(data) << max_size << "bytes ...";
|
||||
|
||||
Reference in New Issue
Block a user