File tree 1 file changed +10
-3
lines changed
crates/cargo-codspeed/src 1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ use codspeed::walltime::get_raw_result_dir_from_workspace_root;
11
11
use glob:: glob;
12
12
use std:: {
13
13
io:: { self , Write } ,
14
+ os:: unix:: process:: ExitStatusExt ,
14
15
path:: { Path , PathBuf } ,
15
16
} ;
16
17
@@ -157,10 +158,16 @@ pub fn run_benches(
157
158
if status. success ( ) {
158
159
Ok ( ( ) )
159
160
} else {
160
- Err ( anyhow ! (
161
+ let code = status
162
+ . code ( )
163
+ . or ( status. signal ( ) . map ( |s| 128 + s) ) // 128+N indicates that a command was interrupted by signal N (see: https://tldp.org/LDP/abs/html/exitcodes.html)
164
+ . unwrap_or ( 1 ) ;
165
+
166
+ eprintln ! (
161
167
"failed to execute the benchmark process, exit code: {}" ,
162
- status. code( ) . unwrap_or( 1 )
163
- ) )
168
+ code
169
+ ) ;
170
+ std:: process:: exit ( code) ;
164
171
}
165
172
} ) ?;
166
173
eprintln ! ( "Done running {}" , bench_name) ;
You can’t perform that action at this time.
0 commit comments