]> spindle.queued.net Git - midori/commitdiff
Fix search engines without %s in the context menu
authorChristian Dywan <christian@twotoasts.de>
Tue, 14 Apr 2009 17:19:50 +0000 (19:19 +0200)
committerChristian Dywan <christian@twotoasts.de>
Tue, 14 Apr 2009 17:19:50 +0000 (19:19 +0200)
midori/midori-view.c

index 3ac7c3042c3517ba2dc7975b56d7225f302c4835..9c0568bb4bac1b72cb36ae2a549b4af149c58174 100644 (file)
@@ -894,12 +894,10 @@ midori_web_view_menu_search_web_activate_cb (GtkWidget*  widget,
         g_object_get (view->settings, "location-entry-search",
                       &search, NULL);
     if (strstr (search, "%s"))
-    {
         uri = g_strdup_printf (search, view->selected_text);
-        g_free (search);
-    }
     else
-        uri = search;
+        uri = g_strconcat (search, view->selected_text, NULL);
+    g_free (search);
 
     g_signal_emit (view, signals[NEW_TAB], 0, uri,
         view->open_tabs_in_the_background);