diff options
author | Andrea Diamantini <adjam7@gmail.com> | 2011-03-10 22:59:51 +0100 |
---|---|---|
committer | Andrea Diamantini <adjam7@gmail.com> | 2011-03-10 22:59:51 +0100 |
commit | a16b8e63aa85625bfb7d75fb4d70c5e6f9bf66ef (patch) | |
tree | a8702d927ca7d8ee6baa20aa50f157044f894fd3 /src/urlbar | |
parent | Another one in the "fixing the dangerous commit" series. (diff) | |
download | rekonq-a16b8e63aa85625bfb7d75fb4d70c5e6f9bf66ef.tar.xz |
Fix crash on "s" type :D
This crash was reported with this bt (reduced here):
Hence, the fix. Just checking if the QBitArray is empty.
Diffstat (limited to 'src/urlbar')
-rw-r--r-- | src/urlbar/listitem.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/urlbar/listitem.cpp b/src/urlbar/listitem.cpp index e1c13ce7..c6f4210e 100644 --- a/src/urlbar/listitem.cpp +++ b/src/urlbar/listitem.cpp @@ -226,6 +226,11 @@ static QString highlightWordsInText(const QString &text, const QStringList &word index = ret.indexOf(wordToPointOut, index + wordToPointOut.size(), Qt::CaseInsensitive); } } + + + if (boldSections.isEmpty()) + return ret; + int numSections = 0; for (int i = 0; i < boldSections.size() - 1; ++i) { |