aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorXan Lopez <xan@src.gnome.org>2009-01-28 01:09:00 +0800
committerXan Lopez <xan@src.gnome.org>2009-01-28 01:09:00 +0800
commitcd161d3195d27e0a10debc7851acc949a92f0db5 (patch)
treed14c61bdac8ad7c38de5466f8c78c4e9930ba2c3
parente7e822df7228edd6af789aac78fb18a131f3f10c (diff)
downloadgsoc2013-epiphany-cd161d3195d27e0a10debc7851acc949a92f0db5.tar
gsoc2013-epiphany-cd161d3195d27e0a10debc7851acc949a92f0db5.tar.gz
gsoc2013-epiphany-cd161d3195d27e0a10debc7851acc949a92f0db5.tar.bz2
gsoc2013-epiphany-cd161d3195d27e0a10debc7851acc949a92f0db5.tar.lz
gsoc2013-epiphany-cd161d3195d27e0a10debc7851acc949a92f0db5.tar.xz
gsoc2013-epiphany-cd161d3195d27e0a10debc7851acc949a92f0db5.tar.zst
gsoc2013-epiphany-cd161d3195d27e0a10debc7851acc949a92f0db5.zip
ephy-find-toolbar: do not search for the empty string or NULL.
Spews critical warnings on console and it's obviously useless. svn path=/trunk/; revision=8736
-rw-r--r--src/ephy-find-toolbar.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/ephy-find-toolbar.c b/src/ephy-find-toolbar.c
index bd550a635..dd2d642e7 100644
--- a/src/ephy-find-toolbar.c
+++ b/src/ephy-find-toolbar.c
@@ -263,6 +263,9 @@ real_find (EphyFindToolbarPrivate *priv,
WebKitWebView *web_view = priv->web_view;
gboolean case_sensitive = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (priv->case_sensitive));
+ if (!priv->find_string || !g_strcmp0 (priv->find_string, ""))
+ return EPHY_FIND_NOTFOUND;
+
if (!webkit_web_view_search_text
(web_view, priv->find_string, case_sensitive, TRUE, FALSE)) {
/* not found, try to wrap */