mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2024-12-13 03:30:33 +00:00
fixing coverity issues
This commit is contained in:
parent
4850944e00
commit
4e2c95d5f5
@ -106,6 +106,7 @@ GalileoE1Pcps8msAmbiguousAcquisition::GalileoE1Pcps8msAmbiguousAcquisition(
|
||||
LOG(WARNING) << item_type_
|
||||
<< " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -116,6 +116,7 @@ GalileoE1PcpsAmbiguousAcquisition::GalileoE1PcpsAmbiguousAcquisition(
|
||||
LOG(WARNING) << item_type_
|
||||
<< " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -106,6 +106,7 @@ GalileoE1PcpsCccwsrAmbiguousAcquisition::GalileoE1PcpsCccwsrAmbiguousAcquisition
|
||||
LOG(WARNING) << item_type_
|
||||
<< " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -140,6 +140,7 @@ GalileoE1PcpsQuickSyncAmbiguousAcquisition::GalileoE1PcpsQuickSyncAmbiguousAcqui
|
||||
LOG(WARNING) << item_type_
|
||||
<< " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -107,6 +107,7 @@ GalileoE1PcpsTongAmbiguousAcquisition::GalileoE1PcpsTongAmbiguousAcquisition(
|
||||
LOG(WARNING) << item_type_
|
||||
<< " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -114,7 +114,7 @@ GalileoE5aNoncoherentIQAcquisitionCaf::GalileoE5aNoncoherentIQAcquisitionCaf(
|
||||
LOG(WARNING) << item_type_
|
||||
<< " unknown acquisition item type";
|
||||
}
|
||||
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
GalileoE5aNoncoherentIQAcquisitionCaf::~GalileoE5aNoncoherentIQAcquisitionCaf()
|
||||
|
@ -121,6 +121,7 @@ GpsL1CaPcpsAcquisition::GpsL1CaPcpsAcquisition(
|
||||
threshold_ = 0.0;
|
||||
doppler_max_ = 0;
|
||||
doppler_step_ = 0;
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -86,6 +86,7 @@ GpsL1CaPcpsAcquisitionFineDoppler::GpsL1CaPcpsAcquisitionFineDoppler(
|
||||
{
|
||||
LOG(WARNING) << item_type_ << " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -85,6 +85,7 @@ GpsL1CaPcpsAssistedAcquisition::GpsL1CaPcpsAssistedAcquisition(
|
||||
{
|
||||
LOG(WARNING) << item_type_ << " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -103,6 +103,7 @@ GpsL1CaPcpsMultithreadAcquisition::GpsL1CaPcpsMultithreadAcquisition(
|
||||
{
|
||||
LOG(WARNING) << item_type_ << " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -102,6 +102,7 @@ GpsL1CaPcpsOpenClAcquisition::GpsL1CaPcpsOpenClAcquisition(
|
||||
{
|
||||
LOG(WARNING) << item_type_ << " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -135,7 +135,7 @@ GpsL1CaPcpsQuickSyncAcquisition::GpsL1CaPcpsQuickSyncAcquisition(
|
||||
LOG(WARNING) << item_type_ << " unknown acquisition item type";
|
||||
}
|
||||
|
||||
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -95,6 +95,7 @@ GpsL1CaPcpsTongAcquisition::GpsL1CaPcpsTongAcquisition(
|
||||
{
|
||||
LOG(WARNING) << item_type_ << " unknown acquisition item type";
|
||||
}
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -118,6 +118,7 @@ GpsL2MPcpsAcquisition::GpsL2MPcpsAcquisition(
|
||||
// LOG(WARNING) << item_type_
|
||||
// << " unknown acquisition item type";
|
||||
// }
|
||||
gnss_synchro_ = {0};
|
||||
}
|
||||
|
||||
|
||||
|
@ -55,9 +55,7 @@ GalileoE1Observables::GalileoE1Observables(ConfigurationInterface* configuration
|
||||
flag_averaging = configuration->property(role + ".flag_averaging", false);
|
||||
dump_ = configuration->property(role + ".dump", false);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_filename);
|
||||
fs_in_ = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
observables_ = galileo_e1_make_observables_cc(in_streams_, queue_, dump_, dump_filename_, output_rate_ms, flag_averaging);
|
||||
observables_->set_fs_in(fs_in_);
|
||||
DLOG(INFO) << "pseudorange(" << observables_->unique_id() << ")";
|
||||
}
|
||||
|
||||
|
@ -82,7 +82,6 @@ public:
|
||||
private:
|
||||
galileo_e1_observables_cc_sptr observables_;
|
||||
bool dump_;
|
||||
unsigned int fs_in_;
|
||||
std::string dump_filename_;
|
||||
std::string role_;
|
||||
unsigned int in_streams_;
|
||||
|
@ -55,9 +55,9 @@ GpsL1CaObservables::GpsL1CaObservables(ConfigurationInterface* configuration,
|
||||
flag_averaging = configuration->property(role + ".flag_averaging", false);
|
||||
dump_ = configuration->property(role + ".dump", false);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_filename);
|
||||
fs_in_ = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
//fs_in_ = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
observables_ = gps_l1_ca_make_observables_cc(in_streams_, queue_, dump_, dump_filename_, output_rate_ms, flag_averaging);
|
||||
observables_->set_fs_in(fs_in_);
|
||||
//observables_->set_fs_in(fs_in_);
|
||||
DLOG(INFO) << "pseudorange(" << observables_->unique_id() << ")";
|
||||
}
|
||||
|
||||
|
@ -81,7 +81,7 @@ public:
|
||||
private:
|
||||
gps_l1_ca_observables_cc_sptr observables_;
|
||||
bool dump_;
|
||||
unsigned int fs_in_;
|
||||
//unsigned int fs_in_;
|
||||
std::string dump_filename_;
|
||||
std::string role_;
|
||||
unsigned int in_streams_;
|
||||
|
@ -55,9 +55,7 @@ HybridObservables::HybridObservables(ConfigurationInterface* configuration,
|
||||
flag_averaging = configuration->property(role + ".flag_averaging", false);
|
||||
dump_ = configuration->property(role + ".dump", false);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_filename);
|
||||
fs_in_ = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
observables_ = hybrid_make_observables_cc(in_streams_, queue_, dump_, dump_filename_, output_rate_ms, flag_averaging);
|
||||
observables_->set_fs_in(fs_in_);
|
||||
DLOG(INFO) << "pseudorange(" << observables_->unique_id() << ")";
|
||||
}
|
||||
|
||||
|
@ -82,7 +82,6 @@ public:
|
||||
private:
|
||||
hybrid_observables_cc_sptr observables_;
|
||||
bool dump_;
|
||||
unsigned int fs_in_;
|
||||
std::string dump_filename_;
|
||||
std::string role_;
|
||||
unsigned int in_streams_;
|
||||
|
@ -116,7 +116,7 @@ int galileo_e1_observables_cc::general_work (int noutput_items, gr_vector_int &n
|
||||
Gnss_Synchro current_gnss_synchro[d_nchannels];
|
||||
std::map<int,Gnss_Synchro> current_gnss_synchro_map;
|
||||
std::map<int,Gnss_Synchro>::iterator gnss_synchro_iter;
|
||||
d_sample_counter++; //count for the processed samples
|
||||
|
||||
/*
|
||||
* 1. Read the GNSS SYNCHRO objects from available channels
|
||||
*/
|
||||
|
@ -61,7 +61,7 @@ class galileo_e1_observables_cc : public gr::block
|
||||
{
|
||||
public:
|
||||
~galileo_e1_observables_cc ();
|
||||
void set_fs_in(unsigned long int fs_in) {d_fs_in = fs_in;};
|
||||
//void set_fs_in(unsigned long int fs_in) {d_fs_in = fs_in;};
|
||||
int general_work (int noutput_items, gr_vector_int &ninput_items,
|
||||
gr_vector_const_void_star &input_items, gr_vector_void_star &output_items);
|
||||
|
||||
@ -74,9 +74,7 @@ private:
|
||||
boost::shared_ptr<gr::msg_queue> d_queue;
|
||||
bool d_dump;
|
||||
bool d_flag_averaging;
|
||||
long int d_sample_counter;
|
||||
unsigned int d_nchannels;
|
||||
unsigned long int d_fs_in;
|
||||
int d_output_rate_ms;
|
||||
std::string d_dump_filename;
|
||||
std::ofstream d_dump_file;
|
||||
|
@ -112,7 +112,6 @@ int gps_l1_ca_observables_cc::general_work (int noutput_items, gr_vector_int &ni
|
||||
std::map<int,Gnss_Synchro> current_gnss_synchro_map;
|
||||
std::map<int,Gnss_Synchro>::iterator gnss_synchro_iter;
|
||||
|
||||
d_sample_counter++; //count for the processed samples
|
||||
/*
|
||||
* 1. Read the GNSS SYNCHRO objects from available channels
|
||||
*/
|
||||
|
@ -59,7 +59,7 @@ class gps_l1_ca_observables_cc : public gr::block
|
||||
{
|
||||
public:
|
||||
~gps_l1_ca_observables_cc ();
|
||||
void set_fs_in(unsigned long int fs_in) {d_fs_in = fs_in;};
|
||||
//void set_fs_in(unsigned long int fs_in) {d_fs_in = fs_in;};
|
||||
int general_work (int noutput_items, gr_vector_int &ninput_items,
|
||||
gr_vector_const_void_star &input_items, gr_vector_void_star &output_items);
|
||||
|
||||
@ -72,9 +72,7 @@ private:
|
||||
boost::shared_ptr<gr::msg_queue> d_queue;
|
||||
bool d_dump;
|
||||
bool d_flag_averaging;
|
||||
long int d_sample_counter;
|
||||
unsigned int d_nchannels;
|
||||
unsigned long int d_fs_in;
|
||||
int d_output_rate_ms;
|
||||
std::string d_dump_filename;
|
||||
std::ofstream d_dump_file;
|
||||
|
@ -120,7 +120,7 @@ int hybrid_observables_cc::general_work (int noutput_items, gr_vector_int &ninpu
|
||||
std::map<int,Gnss_Synchro> current_gnss_synchro_map;
|
||||
std::map<int,Gnss_Synchro> current_gnss_synchro_map_gps_only;
|
||||
std::map<int,Gnss_Synchro>::iterator gnss_synchro_iter;
|
||||
d_sample_counter++; //count for the processed samples
|
||||
|
||||
/*
|
||||
* 1. Read the GNSS SYNCHRO objects from available channels
|
||||
*/
|
||||
|
@ -61,7 +61,7 @@ class hybrid_observables_cc : public gr::block
|
||||
{
|
||||
public:
|
||||
~hybrid_observables_cc ();
|
||||
void set_fs_in(unsigned long int fs_in) {d_fs_in = fs_in;};
|
||||
//void set_fs_in(unsigned long int fs_in) {d_fs_in = fs_in;};
|
||||
int general_work (int noutput_items, gr_vector_int &ninput_items,
|
||||
gr_vector_const_void_star &input_items, gr_vector_void_star &output_items);
|
||||
|
||||
@ -74,9 +74,7 @@ private:
|
||||
boost::shared_ptr<gr::msg_queue> d_queue;
|
||||
bool d_dump;
|
||||
bool d_flag_averaging;
|
||||
long int d_sample_counter;
|
||||
unsigned int d_nchannels;
|
||||
unsigned long int d_fs_in;
|
||||
int d_output_rate_ms;
|
||||
std::string d_dump_filename;
|
||||
std::ofstream d_dump_file;
|
||||
|
@ -57,6 +57,7 @@ protected:
|
||||
Fir_Filter_Test()
|
||||
{
|
||||
queue = gr::msg_queue::make(0);
|
||||
item_size = sizeof(gr_complex);
|
||||
config = std::make_shared<InMemoryConfiguration>();
|
||||
}
|
||||
~Fir_Filter_Test()
|
||||
|
@ -59,6 +59,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE1DllPllVemlTrackingInternalTest()
|
||||
|
@ -61,6 +61,7 @@ protected:
|
||||
stop = false;
|
||||
message = 0;
|
||||
factory = std::make_shared<GNSSBlockFactory>();
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test()
|
||||
|
@ -61,6 +61,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test()
|
||||
|
@ -70,6 +70,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE1PcpsAmbiguousAcquisitionGSoCTest()
|
||||
|
@ -60,6 +60,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE1PcpsAmbiguousAcquisitionTest()
|
||||
|
@ -61,6 +61,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE1PcpsCccwsrAmbiguousAcquisitionTest()
|
||||
|
@ -67,6 +67,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE1PcpsQuickSyncAmbiguousAcquisitionGSoC2014Test()
|
||||
|
@ -67,6 +67,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE1PcpsTongAmbiguousAcquisitionGSoC2013Test()
|
||||
|
@ -62,6 +62,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE5aPcpsAcquisitionGSoC2014GensourceTest()
|
||||
|
@ -58,6 +58,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GalileoE5aTrackingTest()
|
||||
|
@ -62,6 +62,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GpsL1CaPcpsAcquisitionGSoC2013Test()
|
||||
|
@ -62,6 +62,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GpsL1CaPcpsAcquisitionTest()
|
||||
|
@ -66,6 +66,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GpsL1CaPcpsMultithreadAcquisitionGSoC2013Test()
|
||||
@ -91,27 +92,27 @@ protected:
|
||||
int message;
|
||||
boost::thread ch_thread;
|
||||
|
||||
unsigned int integration_time_ms;
|
||||
unsigned int fs_in;
|
||||
unsigned int integration_time_ms = 0;
|
||||
unsigned int fs_in = 0;
|
||||
|
||||
double expected_delay_chips;
|
||||
double expected_doppler_hz;
|
||||
float max_doppler_error_hz;
|
||||
float max_delay_error_chips;
|
||||
double expected_delay_chips = 0.0;
|
||||
double expected_doppler_hz = 0.0;
|
||||
float max_doppler_error_hz = 0.0;
|
||||
float max_delay_error_chips = 0.0;
|
||||
|
||||
unsigned int num_of_realizations;
|
||||
unsigned int realization_counter;
|
||||
unsigned int detection_counter;
|
||||
unsigned int correct_estimation_counter;
|
||||
unsigned int acquired_samples;
|
||||
unsigned int mean_acq_time_us;
|
||||
unsigned int num_of_realizations = 0;
|
||||
unsigned int realization_counter = 0;
|
||||
unsigned int detection_counter = 0;
|
||||
unsigned int correct_estimation_counter = 0;
|
||||
unsigned int acquired_samples = 0;
|
||||
unsigned int mean_acq_time_us = 0;
|
||||
|
||||
double mse_doppler;
|
||||
double mse_delay;
|
||||
double mse_doppler = 0.0;
|
||||
double mse_delay = 0.0;
|
||||
|
||||
double Pd;
|
||||
double Pfa_p;
|
||||
double Pfa_a;
|
||||
double Pd = 0.0;
|
||||
double Pfa_p = 0.0;
|
||||
double Pfa_a = 0.0;
|
||||
};
|
||||
|
||||
void GpsL1CaPcpsMultithreadAcquisitionGSoC2013Test::init()
|
||||
|
@ -62,6 +62,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GpsL1CaPcpsOpenClAcquisitionGSoC2013Test()
|
||||
|
@ -66,6 +66,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GpsL1CaPcpsQuickSyncAcquisitionGSoC2014Test()
|
||||
@ -92,33 +93,33 @@ protected:
|
||||
int message;
|
||||
boost::thread ch_thread;
|
||||
|
||||
unsigned int integration_time_ms;
|
||||
unsigned int fs_in;
|
||||
unsigned int folding_factor;
|
||||
unsigned int integration_time_ms = 0;
|
||||
unsigned int fs_in = 0;
|
||||
unsigned int folding_factor = 0;
|
||||
|
||||
double expected_delay_chips;
|
||||
double expected_doppler_hz;
|
||||
float max_doppler_error_hz;
|
||||
float max_delay_error_chips;
|
||||
double expected_delay_chips = 0.0;
|
||||
double expected_doppler_hz = 0.0;
|
||||
float max_doppler_error_hz = 0.0;
|
||||
float max_delay_error_chips = 0.0;
|
||||
|
||||
unsigned int num_of_realizations;
|
||||
unsigned int realization_counter;
|
||||
unsigned int detection_counter;
|
||||
unsigned int correct_estimation_counter;
|
||||
unsigned int acquired_samples;
|
||||
unsigned int mean_acq_time_us;
|
||||
unsigned int num_of_realizations = 0;
|
||||
unsigned int realization_counter = 0;
|
||||
unsigned int detection_counter = 0;
|
||||
unsigned int correct_estimation_counter = 0;
|
||||
unsigned int acquired_samples = 0;
|
||||
unsigned int mean_acq_time_us = 0;
|
||||
|
||||
double mse_doppler;
|
||||
double mse_delay;
|
||||
double mse_doppler = 0.0;
|
||||
double mse_delay = 0.0;
|
||||
|
||||
double Pd;
|
||||
double Pfa_p;
|
||||
double Pfa_a;
|
||||
double Pmd;
|
||||
double Pd = 0.0;
|
||||
double Pfa_p = 0.0;
|
||||
double Pfa_a = 0.0;
|
||||
double Pmd = 0.0;
|
||||
|
||||
std::ofstream pdpfafile;
|
||||
unsigned int miss_detection_counter;
|
||||
bool dump_test_results;
|
||||
unsigned int miss_detection_counter = 0;
|
||||
bool dump_test_results = false;
|
||||
};
|
||||
|
||||
|
||||
|
@ -63,6 +63,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GpsL1CaPcpsTongAcquisitionGSoC2013Test()
|
||||
|
@ -60,6 +60,7 @@ protected:
|
||||
item_size = sizeof(gr_complex);
|
||||
stop = false;
|
||||
message = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GpsL2MDllPllTrackingTest()
|
||||
|
@ -67,7 +67,8 @@ protected:
|
||||
stop = false;
|
||||
message = 0;
|
||||
sampling_freqeuncy_hz = 0;
|
||||
nsamples=0;
|
||||
nsamples = 0;
|
||||
gnss_synchro = {0};
|
||||
}
|
||||
|
||||
~GpsL2MPcpsAcquisitionTest()
|
||||
|
Loading…
Reference in New Issue
Block a user