mirror of
https://github.com/gabime/spdlog.git
synced 2025-09-30 10:29:02 +08:00
Fixed #1197
This commit is contained in:
@@ -162,6 +162,14 @@ SPDLOG_INLINE void logger::set_error_handler(err_handler handler)
|
||||
custom_err_handler_ = handler;
|
||||
}
|
||||
|
||||
// create new logger with same sinks and configuration.
|
||||
SPDLOG_INLINE std::shared_ptr<logger> logger::clone(std::string logger_name)
|
||||
{
|
||||
auto cloned = std::make_shared<logger>(*this);
|
||||
cloned->name_ = std::move(logger_name);
|
||||
return cloned;
|
||||
}
|
||||
|
||||
// protected methods
|
||||
SPDLOG_INLINE void logger::sink_it_(const details::log_msg &msg)
|
||||
{
|
||||
|
Reference in New Issue
Block a user