From e76fe75c224d2d4abd9736311a9dc8681fd7cea2 Mon Sep 17 00:00:00 2001 From: Andre Puschmann Date: Tue, 3 Apr 2018 12:16:22 +0200 Subject: [PATCH] add missing const keyword to log_filter's members --- lib/include/srslte/common/log.h | 8 ++++---- lib/include/srslte/common/log_filter.h | 20 ++++++++++---------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/lib/include/srslte/common/log.h b/lib/include/srslte/common/log.h index 7d8f0a8cd..b47f79d90 100644 --- a/lib/include/srslte/common/log.h +++ b/lib/include/srslte/common/log.h @@ -129,13 +129,13 @@ public: virtual void debug(const char * message, ...) __attribute__ ((format (printf, 2, 3))) = 0; // Same with hex dump - virtual void error_hex(uint8_t *hex, int size, const char *, ...) __attribute__((format (printf, 4, 5))) + virtual void error_hex(const uint8_t *hex, int size, const char *, ...) __attribute__((format (printf, 4, 5))) {error("error_hex not implemented.\n");} - virtual void warning_hex(uint8_t *hex, int size, const char *, ...) __attribute__((format (printf, 4, 5))) + virtual void warning_hex(const uint8_t *hex, int size, const char *, ...) __attribute__((format (printf, 4, 5))) {error("warning_hex not implemented.\n");} - virtual void info_hex(uint8_t *hex, int size, const char *, ...) __attribute__((format (printf, 4, 5))) + virtual void info_hex(const uint8_t *hex, int size, const char *, ...) __attribute__((format (printf, 4, 5))) {error("info_hex not implemented.\n");} - virtual void debug_hex(uint8_t *hex, int size, const char *, ...) __attribute__((format (printf, 4, 5))) + virtual void debug_hex(const uint8_t *hex, int size, const char *, ...) __attribute__((format (printf, 4, 5))) {error("debug_hex not implemented.\n");} protected: diff --git a/lib/include/srslte/common/log_filter.h b/lib/include/srslte/common/log_filter.h index ea739082a..1296fbbbd 100644 --- a/lib/include/srslte/common/log_filter.h +++ b/lib/include/srslte/common/log_filter.h @@ -57,16 +57,16 @@ public: void init(std::string layer, logger *logger_, bool tti=false); - void console(const char * message, ...); - void error(const char * message, ...); - void warning(const char * message, ...); - void info(const char * message, ...); - void debug(const char * message, ...); - - void error_hex(const uint8_t *hex, int size, const char * message, ...); - void warning_hex(const uint8_t *hex, int size, const char * message, ...); - void info_hex(const uint8_t *hex, int size, const char * message, ...); - void debug_hex(const uint8_t *hex, int size, const char * message, ...); + void console(const char * message, ...) __attribute__ ((format (printf, 2, 3))); + void error(const char * message, ...) __attribute__ ((format (printf, 2, 3))); + void warning(const char * message, ...) __attribute__ ((format (printf, 2, 3))); + void info(const char * message, ...) __attribute__ ((format (printf, 2, 3))); + void debug(const char * message, ...) __attribute__ ((format (printf, 2, 3))); + + void error_hex(const uint8_t *hex, int size, const char * message, ...) __attribute__((format (printf, 4, 5))); + void warning_hex(const uint8_t *hex, int size, const char * message, ...) __attribute__((format (printf, 4, 5))); + void info_hex(const uint8_t *hex, int size, const char * message, ...) __attribute__((format (printf, 4, 5))); + void debug_hex(const uint8_t *hex, int size, const char * message, ...) __attribute__((format (printf, 4, 5))); class time_itf { public: