File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -376,15 +376,15 @@ fn process_events(event_data: EventData) -> anyhow::Result<Counters> {
376
376
/// Given the path to the ETW results file, process it and calculate the
377
377
/// hardware performance counter totals for the rustc process.
378
378
pub fn parse_etw_file ( path : & str ) -> anyhow:: Result < Counters > {
379
- let mut file = std:: io:: BufReader :: new ( std:: fs:: File :: open ( path) . unwrap ( ) ) ;
379
+ let mut file = std:: io:: BufReader :: new ( std:: fs:: File :: open ( path) ? ) ;
380
380
381
- let headers = parse_header ( & mut file) . unwrap ( ) ;
381
+ let headers = parse_header ( & mut file) ? ;
382
382
383
- validate_os_header_line ( & mut file) . unwrap ( ) ;
383
+ validate_os_header_line ( & mut file) ? ;
384
384
385
- let events = parse_events ( & mut file, headers) . unwrap ( ) ;
385
+ let events = parse_events ( & mut file, headers) ? ;
386
386
387
- Ok ( process_events ( events) . unwrap ( ) )
387
+ Ok ( process_events ( events) ? )
388
388
}
389
389
390
390
#[ cfg( test) ]
You can’t perform that action at this time.
0 commit comments