remove extern C flags from common_helper.h

master
Francisco Paisana 4 years ago
parent a2b8bc9e0a
commit 841b884796

@ -31,11 +31,9 @@
#include <fstream> #include <fstream>
#include <thread> #include <thread>
#ifdef __cplusplus namespace srslte {
extern "C" {
#endif // __cplusplus
inline void log_args(int argc, char* argv[], std::string service) inline void log_args(int argc, char* argv[], const std::string& service)
{ {
std::ostringstream s1; std::ostringstream s1;
s1 << "Using binary " << argv[0] << " with arguments: "; s1 << "Using binary " << argv[0] << " with arguments: ";
@ -74,7 +72,6 @@ inline void check_scaling_governor(const std::string& device_name)
} }
} }
#ifdef __cplusplus } // namespace srslte
}
#endif // __cplusplus
#endif // SRSLTE_COMMON_HELPER_H #endif // SRSLTE_COMMON_HELPER_H

@ -455,9 +455,9 @@ int main(int argc, char* argv[])
srslte::logmap::set_default_logger(&log_wrapper); srslte::logmap::set_default_logger(&log_wrapper);
srslte::logmap::get("COMMON")->set_level(srslte::LOG_LEVEL_INFO); srslte::logmap::get("COMMON")->set_level(srslte::LOG_LEVEL_INFO);
log_args(argc, argv, "ENB"); srslte::log_args(argc, argv, "ENB");
check_scaling_governor(args.rf.device_name); srslte::check_scaling_governor(args.rf.device_name);
// Create eNB // Create eNB
unique_ptr<srsenb::enb> enb{new srsenb::enb}; unique_ptr<srsenb::enb> enb{new srsenb::enb};

@ -410,7 +410,7 @@ int main(int argc, char* argv[])
} }
srslte::logmap::set_default_logger(&log_wrapper); srslte::logmap::set_default_logger(&log_wrapper);
log_args(argc, argv, "EPC"); srslte::log_args(argc, argv, "EPC");
srslte::log_filter nas_log; srslte::log_filter nas_log;
nas_log.init("NAS ", &log_wrapper); nas_log.init("NAS ", &log_wrapper);

@ -635,9 +635,9 @@ int main(int argc, char* argv[])
srslog::init(); srslog::init();
srslte::logmap::set_default_logger(&log_wrapper); srslte::logmap::set_default_logger(&log_wrapper);
log_args(argc, argv, "UE"); srslte::log_args(argc, argv, "UE");
check_scaling_governor(args.rf.device_name); srslte::check_scaling_governor(args.rf.device_name);
// Create UE instance // Create UE instance
srsue::ue ue; srsue::ue ue;

Loading…
Cancel
Save