mirror of
https://github.com/sharkdp/hyperfine.git
synced 2026-11-02 09:01:25 +00:00
Proper error handling for the exporter
This commit is contained in:
1 parent
9b5dd60a92
commit
1bd5436109
2 files changed
+8
-9
No files matched your search
+7
-1
@@ -207,7 +207,13 @@ fn main() {
|
||||
|
||||
match res {
|
||||
Ok(timing_results) => {
|
||||
export_manager.write_results(timing_results).unwrap();
|
||||
let ans = export_manager.write_results(timing_results);
|
||||
if let Err(e) = ans {
|
||||
error(&format!(
|
||||
"The following error occured while exporting: {}",
|
||||
e.description()
|
||||
));
|
||||
}
|
||||
}
|
||||
Err(e) => error(e.description()),
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user