Skip to content

Commit

Permalink
fix streaming usage
Browse files Browse the repository at this point in the history
  • Loading branch information
Geal committed Aug 18, 2021
1 parent 272de11 commit b57026b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/number/streaming.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1440,7 +1440,10 @@ where
}
}

let position = position.unwrap_or(i.input_len());
let position = match position {
Some(p) => p,
None => return Err(Err::Incomplete(Needed::new(1))),
};

let index = if zero_count == 0 {
position
Expand Down

0 comments on commit b57026b

Please sign in to comment.