We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 162996e commit 0f52688Copy full SHA for 0f52688
1 file changed
crates/exec-harness/src/lib.rs
@@ -72,7 +72,10 @@ pub fn read_commands_from_stdin() -> Result<Vec<BenchmarkCommand>> {
72
if !stdin_path.is_absolute() {
73
cmd.stdin = Some(
74
std::fs::canonicalize(stdin_path)
75
- .unwrap_or_else(|_| std::env::current_dir().unwrap().join(stdin_path)),
+ .or_else(|_| std::env::current_dir().map(|d| d.join(stdin_path)))
76
+ .with_context(|| {
77
+ format!("Failed to resolve stdin path: {}", stdin_path.display())
78
+ })?,
79
);
80
}
81
0 commit comments