diff --git a/search/query.cpp b/search/query.cpp index c889425bb6..8b1ac77043 100644 --- a/search/query.cpp +++ b/search/query.cpp @@ -176,6 +176,11 @@ void Query::Search(function const & f) return; FlushResults(f); + if (m_resultsRemaining == 0 || m_queryText.empty()) + { + f(Result(string(), string())); // Send last search result marker. + return; + } // Feature matching. FeatureProcessor featureProcessor(*this);