Skip to content

Commit

Permalink
Adding lock to rotate_now() (#3281)
Browse files Browse the repository at this point in the history
  • Loading branch information
matteodelseppia authored Dec 3, 2024
1 parent 65e388e commit 24dde31
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions include/spdlog/sinks/rotating_file_sink-inl.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ SPDLOG_INLINE filename_t rotating_file_sink<Mutex>::filename() {

template <typename Mutex>
SPDLOG_INLINE void rotating_file_sink<Mutex>::rotate_now() {
std::lock_guard<Mutex> lock(base_sink<Mutex>::mutex_);
rotate_();
}

Expand Down

0 comments on commit 24dde31

Please sign in to comment.