If the search started, the current search direction wasn't set but the
resulting direction was calculated upon this value. This leads the search to
start search with the last match found on the page.
gboolean command_search(const Arg *arg)
{
- gboolean forward = !(arg->i ^ vb.state.search_dir);
+ gboolean forward;
if (arg->i == VB_SEARCH_OFF) {
#ifdef FEATURE_SEARCH_HIGHLIGHT
/* set dearch dir only when the searching is started */
vb.state.search_dir = arg->i;
}
+ forward = !(arg->i ^ vb.state.search_dir);
if (vb.state.search_query) {
#ifdef FEATURE_SEARCH_HIGHLIGHT