File tree Expand file tree Collapse file tree 1 file changed +9
-8
lines changed Expand file tree Collapse file tree 1 file changed +9
-8
lines changed Original file line number Diff line number Diff line change @@ -18,16 +18,17 @@ fn main() -> Result<(), Box<dyn Error>> {
18
18
19
19
let data = ProfilingData :: new ( & opt. file_prefix ) ?;
20
20
21
- let global_start_time = data. iter ( ) . map ( |e| e. timestamp . start ( ) ) . min ( ) . unwrap ( ) ;
22
-
23
- for event in data . iter ( ) {
24
- if let Some ( thread_id) = opt . thread_id {
25
- if event . thread_id != thread_id {
26
- continue ;
21
+ if let Some ( global_start_time) = data. iter ( ) . map ( |e| e. timestamp . start ( ) ) . min ( ) {
22
+ for event in data . iter ( ) {
23
+ if let Some ( thread_id ) = opt . thread_id {
24
+ if event . thread_id != thread_id {
25
+ continue ;
26
+ }
27
27
}
28
+ print_event ( & event. to_event ( ) , global_start_time) ;
28
29
}
29
-
30
- print_event ( & event . to_event ( ) , global_start_time ) ;
30
+ } else {
31
+ eprintln ! ( "No events." ) ;
31
32
}
32
33
33
34
Ok ( ( ) )
You can’t perform that action at this time.
0 commit comments