aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2019-07-29 20:25:44 +0200
committerPau Espin Pedrol <pespin@sysmocom.de>2019-07-29 20:42:56 +0200
commit207911bcde98dda058f551d4b22d0d25bec2bd95 (patch)
tree75af32f788776f1dd3d1d43bc7eb6e9202ba4241
parent2c673e0f3ec1853ae93afb06c22ff5af9fe3595b (diff)
usrp1: don't check for non-null underrun pointer
The pointer can't never be null, so avoid checking it. Change-Id: I12e14641713a6494bc89570f02cecfc6f8fd4b5e
-rw-r--r--Transceiver52M/device/usrp1/USRPDevice.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Transceiver52M/device/usrp1/USRPDevice.cpp b/Transceiver52M/device/usrp1/USRPDevice.cpp
index af0b3de..63debee 100644
--- a/Transceiver52M/device/usrp1/USRPDevice.cpp
+++ b/Transceiver52M/device/usrp1/USRPDevice.cpp
@@ -377,7 +377,7 @@ int USRPDevice::readSamples(std::vector<short *> &bufs, int len, bool *overrun,
return len;
}
- if (underrun) *underrun = false;
+ *underrun = false;
uint32_t readBuf[2000];
@@ -427,7 +427,7 @@ int USRPDevice::readSamples(std::vector<short *> &bufs, int len, bool *overrun,
continue;
}
if ((word0 >> 28) & 0x04) {
- if (underrun) *underrun = true;
+ *underrun = true;
LOGC(DDEV, DEBUG) << "UNDERRUN in TRX->USRP interface";
}
if (RSSI) *RSSI = (word0 >> 21) & 0x3f;