diff options
author | Michael West <michael.west@ettus.com> | 2013-11-01 16:28:17 -0700 |
---|---|---|
committer | Michael West <michael.west@ettus.com> | 2013-11-01 16:28:17 -0700 |
commit | e48622be4eb994571e107ed9536f7d8658098396 (patch) | |
tree | f72ad229c2bc9c61b2debb8f43872a6ab10078ae | |
parent | 39acb1ef1701671f47f8712320af351aa16050e3 (diff) | |
download | uhd-e48622be4eb994571e107ed9536f7d8658098396.tar.gz uhd-e48622be4eb994571e107ed9536f7d8658098396.tar.bz2 uhd-e48622be4eb994571e107ed9536f7d8658098396.zip |
Readability improvements and typo fix.
-rw-r--r-- | host/lib/usrp/b200/b200_iface.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/host/lib/usrp/b200/b200_iface.cpp b/host/lib/usrp/b200/b200_iface.cpp index d440b105a..bff075536 100644 --- a/host/lib/usrp/b200/b200_iface.cpp +++ b/host/lib/usrp/b200/b200_iface.cpp @@ -159,7 +159,7 @@ bool parse_record(std::string *record, boost::uint16_t &len, \ std::istringstream(record->substr(3, 4)) >> std::hex >> addr; std::istringstream(record->substr(7, 2)) >> std::hex >> type; - if (len >2 * (record->length() - 9)) // sanity check to prevent buffer overrun + if (len > (2 * (record->length() - 9))) // sanity check to prevent buffer overrun return false; for (i = 0; i < len; i++) { @@ -327,7 +327,7 @@ public: std::string record; file >> record; - if (!record.length() > 0) + if (!(record.length() > 0)) continue; /* Check for valid Intel HEX record. */ @@ -427,7 +427,7 @@ public: UHD_THROW_INVALID_CODE_PATH(); // Below is dead code as long as UHD_THROW_INVALID_CODE_PATH(); is declared above. - // It is preservered here in a comment in case it is needed later: + // It is preserved here in a comment in case it is needed later: // fx3_control_write(B200_VREQ_FPGA_RESET, 0x00, 0x00, data, 4); } |