Skip to content

Commit

Permalink
Fix some missing ticks in 0.32.0 (#210)
Browse files Browse the repository at this point in the history
  • Loading branch information
LaihoE authored Aug 22, 2024
1 parent f0ea617 commit 62dfacb
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/parser/src/parse_demo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,10 @@ impl<'a> Parser<'a> {
return thread::scope(|s| {
let _handle = s.spawn(|| fp.par_start(demo_bytes, sender));
let mut first_pass_parser = FirstPassParser::new(&self.input);
let first_pass_output = first_pass_parser.parse_demo(&demo_bytes, true).unwrap();
let out = self.second_pass_threaded_with_channels(demo_bytes, first_pass_output, receiver);
out
match first_pass_parser.parse_demo(&demo_bytes, true) {
Ok(first_pass_output) => self.second_pass_threaded_with_channels(demo_bytes, first_pass_output, receiver),
Err(e) => Err(e),
}
});
}
// Single threaded second pass
Expand Down Expand Up @@ -129,6 +130,8 @@ impl<'a> Parser<'a> {
}
// Fallback if channels failed to find all fullpackets. Should be rare.
if !channel_threading_was_ok {
let mut first_pass_parser = FirstPassParser::new(&self.input);
let first_pass_output = first_pass_parser.parse_demo(outer_bytes, false)?;
return self.second_pass_multi_threaded_no_channels(outer_bytes, first_pass_output);
}
// check for errors
Expand Down

0 comments on commit 62dfacb

Please sign in to comment.