Skip to content

Commit

Permalink
fix: #50
Browse files Browse the repository at this point in the history
  • Loading branch information
BinChengZhao committed Jan 8, 2024
1 parent 69a3867 commit 1ccaac0
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "delay_timer"
version = "0.11.4"
version = "0.11.5"
authors = ["binchengZhao <[email protected]>"]
edition = "2018"
repository = "https://github.com/BinChengZhao/delay-timer"
Expand Down
5 changes: 3 additions & 2 deletions build/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,9 @@ fn main() -> Result<()> {
}
}

// Check for a minimum version
if version()? >= Version::parse("1.51.0")? {
// When the rustc version is >= 1.51.0 and < 1.75.0, we can use the
let version = version()?;
if version >= Version::parse("1.51.0")? && version < Version::parse("1.75.0")? {
println!("cargo:rustc-cfg=SPLIT_INCLUSIVE_COMPATIBLE");
}

Expand Down
5 changes: 4 additions & 1 deletion src/timer/runtime_trace/task_instance.rs
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,10 @@ impl TaskInstancesChainMaintainer {
self.inner_sender
.send(instance.clone())
.await
.map_or((), |_| {});
.map_err(|e| {
tracing::error!("push_instance error: {:?}", e);
})
.ok();
self.inner_list.push_back(instance);
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/utils/parse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ pub mod shell_command {
//By Option(Some(Result<T>)), determine if there is an output stdio..
//By Result<T>(OK(t)), determine if there is success open file.
#[cfg(not(SPLIT_INCLUSIVE_COMPATIBLE))]
fn _has_redirect_file(command: &str) -> Option<Result<File>> {
fn _has_redirect_file(command: &str) -> Option<Result<File, AnyhowError>> {
let angle_bracket = if command.contains(">>") {
">>"
} else if command.contains('>') {
Expand Down

0 comments on commit 1ccaac0

Please sign in to comment.