Skip to content

Commit 9e5c40d

Browse files
committed
Merge branch 'backport-v0.3.13'
2 parents dfca4a8 + d715703 commit 9e5c40d

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

spdlog/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "spdlog-rs"
3-
version = "0.3.12"
3+
version = "0.3.13"
44
edition = "2021"
55
rust-version = "1.56"
66
description = "A fast and combinable Rust logging crate, inspired by the C++ logging library spdlog"

spdlog/src/periodic_worker.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@ impl PeriodicWorker {
2121
Self {
2222
active: active.clone(),
2323
thread: Some(thread::spawn(move || loop {
24-
let guard = active.0.lock_expect();
25-
let (_, res) = active
24+
let flag = active.0.lock_expect();
25+
let (flag, res) = active
2626
.1
27-
.wait_timeout_while(guard, interval, |active| *active)
27+
.wait_timeout_while(flag, interval, |flag| *flag)
2828
.unwrap();
2929

30-
if !res.timed_out() || !callback() {
30+
if !res.timed_out() || !*flag || !callback() {
3131
return;
3232
}
3333
})),

0 commit comments

Comments
 (0)