e1608: scan review fixes (EINTR in Scan::poll, cfg-based broadcast test, no per-tick copy)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
8245324b51
commit
f74df49d33
3 files changed
+16
-13
No files matched your search
@@ -291,7 +291,10 @@ const std::vector<DeviceInfo>& Scan::poll() {
|
||||
socklen_t flen = sizeof from;
|
||||
const ssize_t n = ::recvfrom(s.get(), buf, sizeof buf, MSG_DONTWAIT,
|
||||
reinterpret_cast<sockaddr*>(&from), &flen);
|
||||
if (n < 0) break; // nothing more on this socket for now
|
||||
if (n < 0) {
|
||||
if (errno == EINTR) continue;
|
||||
break; // nothing more on this socket for now
|
||||
}
|
||||
take_reply(buf, n, from, found_);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user