changeset 20632:9e3b3aca6ead stable

prevent doc browser from searching for an empty string (bug 46227) * webinfo.cc (search): just return if search text is empty or only contains whitespace
author Torsten <ttl@justmail.de>
date Sat, 17 Oct 2015 09:41:07 +0200
parents 802dc52d4d46
children 1c4c4bb8be94
files libgui/src/qtinfo/webinfo.cc
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libgui/src/qtinfo/webinfo.cc	Fri Oct 16 11:03:26 2015 +0200
+++ b/libgui/src/qtinfo/webinfo.cc	Sat Oct 17 09:41:07 2015 +0200
@@ -241,6 +241,9 @@
 void
 webinfo::search ()
 {
+  if (_search_line_edit->text ().trimmed ().isEmpty ())
+    return;   // do nothing if search field is empty or only has whitespaces
+
   if (_search_check_box->isChecked ())
     {
       // Global search