1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2025-10-26 04:57:40 +00:00

clang-tidy fixes

This commit is contained in:
Carles Fernandez
2019-02-11 17:15:48 +01:00
parent dfc963ad86
commit 45b4478047
4 changed files with 12 additions and 12 deletions

View File

@@ -605,14 +605,14 @@ private:
class Rtcm_Listener_Room class Rtcm_Listener_Room
{ {
public: public:
inline void join(std::shared_ptr<Rtcm_Listener> participant) inline void join(const std::shared_ptr<Rtcm_Listener>& participant)
{ {
participants_.insert(participant); participants_.insert(participant);
for (auto msg : recent_msgs_) for (auto msg : recent_msgs_)
participant->deliver(msg); participant->deliver(msg);
} }
inline void leave(std::shared_ptr<Rtcm_Listener> participant) inline void leave(const std::shared_ptr<Rtcm_Listener>& participant)
{ {
participants_.erase(participant); participants_.erase(participant);
} }
@@ -754,7 +754,7 @@ private:
boost::asio::ip::tcp::resolver::iterator endpoint_iterator) boost::asio::ip::tcp::resolver::iterator endpoint_iterator)
: io_context_(io_context), socket_(io_context) : io_context_(io_context), socket_(io_context)
{ {
do_connect(endpoint_iterator); do_connect(std::move(endpoint_iterator));
} }
inline void close() inline void close()
@@ -778,7 +778,7 @@ private:
private: private:
inline void do_connect(boost::asio::ip::tcp::resolver::iterator endpoint_iterator) inline void do_connect(boost::asio::ip::tcp::resolver::iterator endpoint_iterator)
{ {
boost::asio::async_connect(socket_, endpoint_iterator, boost::asio::async_connect(socket_, std::move(endpoint_iterator),
[this](boost::system::error_code ec, boost::asio::ip::tcp::resolver::iterator) { [this](boost::system::error_code ec, boost::asio::ip::tcp::resolver::iterator) {
if (!ec) if (!ec)
{ {

View File

@@ -34,11 +34,11 @@ extern "C"
* instead of default local one. * instead of default local one.
* On error returns -1 and errno set to EINVAL * On error returns -1 and errno set to EINVAL
*/ */
time_t asn_GT2time(const GeneralizedTime_t *, struct tm *_optional_tm4fill, time_t asn_GT2time(const GeneralizedTime_t * /*st*/, struct tm *_optional_tm4fill,
int as_gmt); int as_gmt);
/* A version of the above function also returning the fractions of seconds */ /* A version of the above function also returning the fractions of seconds */
time_t asn_GT2time_frac(const GeneralizedTime_t *, time_t asn_GT2time_frac(const GeneralizedTime_t * /*st*/,
int *frac_value, int *frac_digits, /* (value / (10 ^ digits)) */ int *frac_value, int *frac_digits, /* (value / (10 ^ digits)) */
struct tm *_optional_tm4fill, int as_gmt); struct tm *_optional_tm4fill, int as_gmt);
@@ -47,7 +47,7 @@ extern "C"
* For example, parsing of the time ending with ".1" seconds * For example, parsing of the time ending with ".1" seconds
* with frac_digits=3 (msec) would yield frac_value = 100. * with frac_digits=3 (msec) would yield frac_value = 100.
*/ */
time_t asn_GT2time_prec(const GeneralizedTime_t *, time_t asn_GT2time_prec(const GeneralizedTime_t * /*st*/,
int *frac_value, int frac_digits, int *frac_value, int frac_digits,
struct tm *_optional_tm4fill, int as_gmt); struct tm *_optional_tm4fill, int as_gmt);
@@ -59,9 +59,9 @@ extern "C"
* On error, this function returns 0 and sets errno. * On error, this function returns 0 and sets errno.
*/ */
GeneralizedTime_t *asn_time2GT(GeneralizedTime_t *_optional_gt, GeneralizedTime_t *asn_time2GT(GeneralizedTime_t *_optional_gt,
const struct tm *, int force_gmt); const struct tm * /*tm*/, int force_gmt);
GeneralizedTime_t *asn_time2GT_frac(GeneralizedTime_t *_optional_gt, GeneralizedTime_t *asn_time2GT_frac(GeneralizedTime_t *_optional_gt,
const struct tm *, int frac_value, int frac_digits, int force_gmt); const struct tm * /*tm*/, int frac_value, int frac_digits, int force_gmt);
#ifdef __cplusplus #ifdef __cplusplus
} }

View File

@@ -27,10 +27,10 @@ extern "C"
struct tm; /* <time.h> */ struct tm; /* <time.h> */
/* See asn_GT2time() in GeneralizedTime.h */ /* See asn_GT2time() in GeneralizedTime.h */
time_t asn_UT2time(const UTCTime_t *, struct tm *_optional_tm4fill, int as_gmt); time_t asn_UT2time(const UTCTime_t * /*st*/, struct tm *_optional_tm4fill, int as_gmt);
/* See asn_time2GT() in GeneralizedTime.h */ /* See asn_time2GT() in GeneralizedTime.h */
UTCTime_t *asn_time2UT(UTCTime_t *__opt_ut, const struct tm *, int force_gmt); UTCTime_t *asn_time2UT(UTCTime_t *__opt_ut, const struct tm * /*tm*/, int force_gmt);
#ifdef __cplusplus #ifdef __cplusplus
} }

View File

@@ -34,7 +34,7 @@ extern "C"
* Return values correspond to their libc counterparts (if any). * Return values correspond to their libc counterparts (if any).
*/ */
ssize_t ber_tlv_tag_snprint(ber_tlv_tag_t tag, char *buf, size_t buflen); ssize_t ber_tlv_tag_snprint(ber_tlv_tag_t tag, char *buf, size_t buflen);
ssize_t ber_tlv_tag_fwrite(ber_tlv_tag_t tag, FILE *); ssize_t ber_tlv_tag_fwrite(ber_tlv_tag_t tag, FILE * /*f*/);
char *ber_tlv_tag_string(ber_tlv_tag_t tag); char *ber_tlv_tag_string(ber_tlv_tag_t tag);