mirror of
				https://github.com/gnss-sdr/gnss-sdr
				synced 2025-10-31 07:13:03 +00:00 
			
		
		
		
	Remove useless casts
This commit is contained in:
		| @@ -383,7 +383,7 @@ size_t FileSourceBase::samplesToSkip() const | ||||
|  | ||||
| size_t FileSourceBase::computeSamplesInFile() const | ||||
| { | ||||
|     auto n_samples = static_cast<size_t>(samples()); | ||||
|     auto n_samples = samples(); | ||||
|  | ||||
|     // this could throw, but the existence of the file has been proven before we get here. | ||||
|     const auto size = fs::file_size(filename()); | ||||
|   | ||||
| @@ -69,7 +69,7 @@ FourBitCpxFileSignalSource::FourBitCpxFileSignalSource( | ||||
| std::tuple<size_t, bool> FourBitCpxFileSignalSource::itemTypeToSize() | ||||
| { | ||||
|     auto is_complex = false; | ||||
|     auto item_size = size_t(sizeof(char));  // default | ||||
|     auto item_size = sizeof(char);  // default | ||||
|  | ||||
|     if (item_type() == "byte") | ||||
|         { | ||||
|   | ||||
| @@ -40,7 +40,7 @@ NsrFileSignalSource::NsrFileSignalSource(const ConfigurationInterface* configura | ||||
| std::tuple<size_t, bool> NsrFileSignalSource::itemTypeToSize() | ||||
| { | ||||
|     auto is_complex = false; | ||||
|     auto item_size = size_t(sizeof(char));  // default | ||||
|     auto item_size = sizeof(char);  // default | ||||
|  | ||||
|     if (item_type() == "byte") | ||||
|         { | ||||
|   | ||||
| @@ -43,7 +43,7 @@ TwoBitCpxFileSignalSource::TwoBitCpxFileSignalSource( | ||||
| std::tuple<size_t, bool> TwoBitCpxFileSignalSource::itemTypeToSize() | ||||
| { | ||||
|     auto is_complex = false; | ||||
|     auto item_size = size_t(sizeof(char));  // default | ||||
|     auto item_size = sizeof(char);  // default | ||||
|  | ||||
|     if (item_type() == "byte") | ||||
|         { | ||||
|   | ||||
| @@ -49,7 +49,7 @@ TwoBitPackedFileSignalSource::TwoBitPackedFileSignalSource( | ||||
| std::tuple<size_t, bool> TwoBitPackedFileSignalSource::itemTypeToSize() | ||||
| { | ||||
|     auto is_complex_t = false; | ||||
|     auto item_size = size_t(sizeof(char));  // default | ||||
|     auto item_size = sizeof(char);  // default | ||||
|  | ||||
|     if (item_type() == "byte") | ||||
|         { | ||||
|   | ||||
| @@ -43,7 +43,7 @@ ZmqSignalSource::ZmqSignalSource(const ConfigurationInterface* configuration, | ||||
|         { | ||||
|             LOG(INFO) << "Connecting to ZMQ pub at " << endpoint; | ||||
|             // work around gnuradio interface const-deficiency | ||||
|             d_source_block = gr::zeromq::sub_source::make(d_item_size, vlen, const_cast<char*>(endpoint.data()), timeout_ms, pass_tags, hwm); | ||||
|             d_source_block = gr::zeromq::sub_source::make(d_item_size, vlen, endpoint.data(), timeout_ms, pass_tags, hwm); | ||||
|  | ||||
|             // work around another bug. GNU Radio passes tags through the ZMQ block | ||||
|             // unconditionally if pass_tags is true, but that flag controls protocol more | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Carles Fernandez
					Carles Fernandez