aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrej Rode <andrej.rode@ettus.com>2016-11-17 16:12:47 -0800
committerMartin Braun <martin.braun@ettus.com>2016-12-08 14:32:58 -0800
commit5efe1c0f124d1068bbc9bd882db5530ca2ca0377 (patch)
treebd003671e5fb76484439827422b085bd638b03f1
parenta2e59940dcdeb7ba120339a823c34f8d31cf322e (diff)
downloaduhd-5efe1c0f124d1068bbc9bd882db5530ca2ca0377.tar.gz
uhd-5efe1c0f124d1068bbc9bd882db5530ca2ca0377.tar.bz2
uhd-5efe1c0f124d1068bbc9bd882db5530ca2ca0377.zip
X300: dont stop x300_find if receiving wrong flags
Just skip current receive buffer and do not stop processing udp packets completely.
-rw-r--r--host/lib/usrp/x300/x300_impl.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/host/lib/usrp/x300/x300_impl.cpp b/host/lib/usrp/x300/x300_impl.cpp
index 494598bf3..fffd6ecac 100644
--- a/host/lib/usrp/x300/x300_impl.cpp
+++ b/host/lib/usrp/x300/x300_impl.cpp
@@ -105,8 +105,8 @@ static device_addrs_t x300_find_with_addr(const device_addr_t &hint)
const size_t nbytes = comm->recv(asio::buffer(buff), 0.050);
if (nbytes == 0) break;
const x300_fw_comms_t *reply = (const x300_fw_comms_t *)buff;
- if (request.flags != reply->flags) break;
- if (request.sequence != reply->sequence) break;
+ if (request.flags != reply->flags) continue;
+ if (request.sequence != reply->sequence) continue;
device_addr_t new_addr;
new_addr["type"] = "x300";
new_addr["addr"] = comm->get_recv_addr();