git-svn-id: svn://db.shs.com.ru/pip@699 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5

This commit is contained in:
2019-02-06 20:20:23 +00:00
parent b31352ffb1
commit b2c76a0e1b
14 changed files with 41 additions and 39 deletions

View File

@@ -199,7 +199,7 @@ void PIIODevice::write_func() {
int ret = write(item.first);
threadedWriteEvent(item.second, ret);
}
msleep(1);
msleep(PIP_MIN_MSLEEP);
}
}
@@ -279,7 +279,7 @@ PIByteArray PIIODevice::readForTime(double timeout_ms) {
tm.reset();
while (tm.elapsed_m() < timeout_ms) {
ret = read(td, threadedReadBufferSize());
if (ret <= 0) msleep(1);
if (ret <= 0) msleep(PIP_MIN_MSLEEP);
else str.append(td, ret);
}
delete[] td;