From 104e2480542dcf197367956832392b4b475817e9 Mon Sep 17 00:00:00 2001 From: Daniel Carl Date: Thu, 25 Jul 2013 11:37:58 +0200 Subject: [PATCH] Don't try to search multiple time for none found string. --- src/command.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/command.c b/src/command.c index 9d761da..466a2e5 100644 --- a/src/command.c +++ b/src/command.c @@ -593,7 +593,9 @@ gboolean command_search(const Arg *arg) /* make sure we have a count greater than 0 */ vb.state.count = vb.state.count ? vb.state.count : 1; do { - webkit_web_view_search_text(vb.gui.webview, vb.state.search_query, false, forward, true); + if (!webkit_web_view_search_text(vb.gui.webview, vb.state.search_query, false, forward, true)) { + break; + } } while (--vb.state.count); } -- 2.20.1