We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0d14027 commit da902d8Copy full SHA for da902d8
src/reading.rs
@@ -929,6 +929,13 @@ impl<T :io::Read + io::Seek> PacketReader<T> {
929
// Seek to the start of the file to get the starting boundary
930
try!(self.rdr.seek(SeekFrom::Start(0)));
931
let (mut begin_pos, mut begin_pg) = pg_read_match_serial!();
932
+
933
+ // If the goal is the beginning, we are done.
934
+ if pos_goal == 0 {
935
+ //println!("Seeking to the beginning of the stream - skipping bisect.");
936
+ found!(begin_pos);
937
+ }
938
939
// Seek to the end of the file to get the ending boundary
940
// TODO the 200 KB is just a guessed number, any ideas
941
// to improve it?
0 commit comments