Fix some issues with trailing junk in files.
1) We were treating EOF in op_get_next_page() as a read error when called from op_get_prev_page_serial(). 2) We also assumed op_get_prev_page_serial() stopped scanning at the end of the page it returned, in order to compute the size of that page. Return the page size explicitly instead. 3) Finally, once we discover where the last page is, there is no reason to ever look at data past it. Update 'end' once we find it, and always pass that to op_get_next_page().
Loading
Please register or sign in to comment