aboutsummaryrefslogtreecommitdiffstats
path: root/host/examples/rx_timed_samples.cpp
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2017-06-27 19:06:50 -0700
committerMartin Braun <martin.braun@ettus.com>2017-06-29 13:40:07 -0700
commit47cdd6319c74a7b823843aad5ff3fa370ed1e6ef (patch)
tree216e88f36dbb5ba0b933f0a5ec3c2a151e972589 /host/examples/rx_timed_samples.cpp
parent412a7053cc0698fd8e1a09d9c40ec2f96cf629af (diff)
downloaduhd-47cdd6319c74a7b823843aad5ff3fa370ed1e6ef.tar.gz
uhd-47cdd6319c74a7b823843aad5ff3fa370ed1e6ef.tar.bz2
uhd-47cdd6319c74a7b823843aad5ff3fa370ed1e6ef.zip
uhd: Replaced many lexical_cast with appropriate C++11 equivalents
Diffstat (limited to 'host/examples/rx_timed_samples.cpp')
-rw-r--r--host/examples/rx_timed_samples.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/host/examples/rx_timed_samples.cpp b/host/examples/rx_timed_samples.cpp
index 20abd92fe..a0f7e2821 100644
--- a/host/examples/rx_timed_samples.cpp
+++ b/host/examples/rx_timed_samples.cpp
@@ -72,11 +72,11 @@ int UHD_SAFE_MAIN(int argc, char *argv[]){
std::vector<size_t> channel_nums;
boost::split(channel_strings, channel_list, boost::is_any_of("\"',"));
for(size_t ch = 0; ch < channel_strings.size(); ch++){
- size_t chan = boost::lexical_cast<int>(channel_strings[ch]);
+ size_t chan = std::stoi(channel_strings[ch]);
if(chan >= usrp->get_tx_num_channels() or chan >= usrp->get_rx_num_channels()){
throw std::runtime_error("Invalid channel(s) specified.");
}
- else channel_nums.push_back(boost::lexical_cast<int>(channel_strings[ch]));
+ else channel_nums.push_back(std::stoi(channel_strings[ch]));
}
//set the rx sample rate