aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/common/async_packet_handler.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'host/lib/usrp/common/async_packet_handler.hpp')
-rw-r--r--host/lib/usrp/common/async_packet_handler.hpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/host/lib/usrp/common/async_packet_handler.hpp b/host/lib/usrp/common/async_packet_handler.hpp
index 20409c77a..4b162677b 100644
--- a/host/lib/usrp/common/async_packet_handler.hpp
+++ b/host/lib/usrp/common/async_packet_handler.hpp
@@ -40,7 +40,11 @@ namespace uhd{ namespace usrp{
//load into metadata
metadata.channel = channel;
metadata.has_time_spec = if_packet_info.has_tsf;
- metadata.time_spec = time_spec_t::from_ticks(if_packet_info.tsf, tick_rate);
+ if (tick_rate == 0.0) {
+ metadata.time_spec = 0.0;
+ } else {
+ metadata.time_spec = time_spec_t::from_ticks(if_packet_info.tsf, tick_rate);
+ }
metadata.event_code = async_metadata_t::event_code_t(to_host(payload[0]) & 0xff);
//load user payload