- Fix unused variable in buffer_pool.h

- Replaced logger to srslog in log_args utility function.
master
faluco 4 years ago committed by faluco
parent d37a07a47f
commit c8a4bf2613

@ -167,11 +167,7 @@ public:
static std::unique_ptr<byte_buffer_pool> instance; static std::unique_ptr<byte_buffer_pool> instance;
static byte_buffer_pool* get_instance(int capacity = -1); static byte_buffer_pool* get_instance(int capacity = -1);
static void cleanup(); static void cleanup();
byte_buffer_pool(int capacity = -1) byte_buffer_pool(int capacity = -1) { pool = new buffer_pool<byte_buffer_t>(capacity); }
{
log = nullptr;
pool = new buffer_pool<byte_buffer_t>(capacity);
}
byte_buffer_pool(const byte_buffer_pool& other) = delete; byte_buffer_pool(const byte_buffer_pool& other) = delete;
byte_buffer_pool& operator=(const byte_buffer_pool& other) = delete; byte_buffer_pool& operator=(const byte_buffer_pool& other) = delete;
~byte_buffer_pool() { delete pool; } ~byte_buffer_pool() { delete pool; }

@ -19,6 +19,7 @@
#define SRSLTE_COMMON_HELPER_H #define SRSLTE_COMMON_HELPER_H
#include "srslte/common/logmap.h" #include "srslte/common/logmap.h"
#include "srslte/srslog/srslog.h"
#include <fstream> #include <fstream>
#include <sstream> #include <sstream>
#include <thread> #include <thread>
@ -34,8 +35,8 @@ inline void log_args(int argc, char* argv[], const std::string& service)
} }
s1 << std::endl; s1 << std::endl;
srslte::logmap::get(service)->set_level(srslte::LOG_LEVEL_INFO); srslog::fetch_basic_logger(service, false).set_level(srslog::basic_levels::info);
srslte::logmap::get(service)->info("%s", s1.str().c_str()); srslog::fetch_basic_logger(service).info("%s", s1.str().c_str());
} }
inline void check_scaling_governor(const std::string& device_name) inline void check_scaling_governor(const std::string& device_name)

Loading…
Cancel
Save