diff options
-rw-r--r-- | host/include/uhd/config.hpp | 8 | ||||
-rw-r--r-- | host/lib/transport/vrt_packet_handler.hpp | 2 |
2 files changed, 8 insertions, 2 deletions
diff --git a/host/include/uhd/config.hpp b/host/include/uhd/config.hpp index 013354d33..2360174a4 100644 --- a/host/include/uhd/config.hpp +++ b/host/include/uhd/config.hpp @@ -38,11 +38,17 @@ # pragma warning(disable: 4250) // 'class' : inherits 'method' via dominance #endif -//define logical operators +// define logical operators #ifdef BOOST_MSVC #include <ciso646> #endif +// define ssize_t +#ifdef BOOST_MSVC + #include <cstddef> + typedef ptrdiff_t ssize_t; +#endif + // http://gcc.gnu.org/wiki/Visibility // Generic helper definitions for shared library support #if defined(BOOST_HAS_DECLSPEC) diff --git a/host/lib/transport/vrt_packet_handler.hpp b/host/lib/transport/vrt_packet_handler.hpp index 221e2bfa6..702d3bfb9 100644 --- a/host/lib/transport/vrt_packet_handler.hpp +++ b/host/lib/transport/vrt_packet_handler.hpp @@ -329,7 +329,7 @@ namespace vrt_packet_handler{ ); //commit the samples to the zero-copy interface - if (send_buffs[i]->commit(if_packet_info.num_packet_words32*sizeof(boost::uint32_t)) < num_samps){ + if (send_buffs[i]->commit(if_packet_info.num_packet_words32*sizeof(boost::uint32_t)) < ssize_t(num_samps)){ std::cerr << "commit to send buffer returned less than commit size" << std::endl; } } |