diff options
Diffstat (limited to 'host/lib/usrp/usrp2/io_impl.cpp')
-rw-r--r-- | host/lib/usrp/usrp2/io_impl.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/host/lib/usrp/usrp2/io_impl.cpp b/host/lib/usrp/usrp2/io_impl.cpp index 9299bb04a..642b6b08b 100644 --- a/host/lib/usrp/usrp2/io_impl.cpp +++ b/host/lib/usrp/usrp2/io_impl.cpp @@ -198,11 +198,12 @@ size_t usrp2_impl::send( ); //copy in the vrt header (yes we left space) - std::memcpy(items - num_header_words32, vrt_hdr, num_header_words32); - asio::const_buffer send_buff(items - num_header_words32, num_packet_words32*sizeof(uint32_t)); + items -= num_header_words32; + std::memcpy(items, vrt_hdr, num_header_words32*sizeof(uint32_t)); //send and return number of samples - _data_transport->send(send_buff); return num_samps; + _data_transport->send(asio::buffer(items, num_packet_words32*sizeof(uint32_t))); + return num_samps; } /*********************************************************************** |