Mistake in the search function

Corrected a little mistake in the search function so that it does not
start the search on the current page
This commit is contained in:
Moritz Lipp 2010-01-28 23:35:42 +01:00
parent c7ae813201
commit ad897d2c65

View file

@ -792,7 +792,7 @@ search(void* parameter)
if(argument->n)
direction = (argument->n == BACKWARD) ? -1 : 1;
for(page_counter = 0; page_counter < Zathura.PDF.number_of_pages; page_counter++)
for(page_counter = 1; page_counter <= Zathura.PDF.number_of_pages; page_counter++)
{
next_page = (Zathura.PDF.number_of_pages + Zathura.PDF.page_number +
page_counter * direction) % Zathura.PDF.number_of_pages;