Skip to content

Commit

Permalink
Omit infinite loop by searching empty RegularExpression
Browse files Browse the repository at this point in the history
  • Loading branch information
joern274 committed Nov 14, 2023
1 parent 163f844 commit 2e941f9
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions plugins/gui/src/comment_system/widgets/comment_item.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ namespace hal

bool CommentItem::search(const QString &string, SearchOptions searchOpts)
{
if (string.isEmpty()) return false;
mHeader->handleSearchChanged(string,searchOpts.toInt());
bool found = mHeader->hasMatch();
QList<QTextEdit::ExtraSelection> extraSelections;
Expand Down

0 comments on commit 2e941f9

Please sign in to comment.