From ea84c1ec2750529ec10b5f5ea2b99a13327b230a Mon Sep 17 00:00:00 2001 From: Carles Fernandez Date: Thu, 24 Aug 2017 18:03:23 +0200 Subject: [PATCH] Fix redefinition of variable --- ...ps_quicksync_ambiguous_acquisition_gsoc2014_test.cc | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/tests/unit-tests/signal-processing-blocks/acquisition/galileo_e1_pcps_quicksync_ambiguous_acquisition_gsoc2014_test.cc b/src/tests/unit-tests/signal-processing-blocks/acquisition/galileo_e1_pcps_quicksync_ambiguous_acquisition_gsoc2014_test.cc index f059c7a1b..37d6a8813 100644 --- a/src/tests/unit-tests/signal-processing-blocks/acquisition/galileo_e1_pcps_quicksync_ambiguous_acquisition_gsoc2014_test.cc +++ b/src/tests/unit-tests/signal-processing-blocks/acquisition/galileo_e1_pcps_quicksync_ambiguous_acquisition_gsoc2014_test.cc @@ -109,6 +109,7 @@ GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test_msg_rx::GalileoE1PcpsQuic rx_message = 0; } + GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test_msg_rx::~GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test_msg_rx() {} @@ -127,7 +128,6 @@ protected: gnss_synchro = Gnss_Synchro(); init(); } - ~GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test() { } @@ -201,6 +201,7 @@ void GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test::init() Pmd = 0; } + void GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test::config_1() { gnss_synchro.Channel_ID = 0; @@ -273,6 +274,7 @@ void GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test::config_1() config->set_property("Acquisition.dump", "false"); } + void GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test::config_2() { gnss_synchro.Channel_ID = 0; @@ -458,12 +460,14 @@ void GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test::config_3() config->set_property("Acquisition.dump", "false"); } + void GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test::start_queue() { stop = false; ch_thread = boost::thread(&GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test::wait_message, this); } + void GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test::wait_message() { std::chrono::time_point begin, end; @@ -478,7 +482,7 @@ void GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test::wait_message() channel_internal_queue.wait_and_pop(message); end = std::chrono::system_clock::now(); - std::chrono::duration elapsed_seconds = end - begin; + elapsed_seconds = end - begin; mean_acq_time_us += elapsed_seconds.count() * 1e6; @@ -582,7 +586,7 @@ TEST_F(GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test, ConnectAndRun) begin = std::chrono::system_clock::now(); top_block->run(); // Start threads and wait end = std::chrono::system_clock::now(); - std::chrono::duration elapsed_seconds = end - begin; + elapsed_seconds = end - begin; }) << "Failure running the top_block."<< std::endl; std::cout << "Processed " << nsamples << " samples in " << elapsed_seconds.count() * 1e6 << " microseconds" << std::endl;