diff options
author | John Thacker <johnthacker@gmail.com> | 2023-02-24 21:56:20 -0500 |
---|---|---|
committer | John Thacker <johnthacker@gmail.com> | 2023-02-25 18:50:56 +0000 |
commit | 641434ff81d454ef6ffa0c164a969fcb5b850cff (patch) | |
tree | 58001329b8216373557d937c5f683c7a4b3115f6 /ui | |
parent | b1460bff699f56886386388cd559b2526735ed61 (diff) |
Qt: Fix leak in Coloring Rules Dialog
We don't need the cloned color_filter_t after the ColoringRuleItem
has been created (the char* strings are copied into QStrings), so
free it.
Diffstat (limited to 'ui')
-rw-r--r-- | ui/qt/models/coloring_rules_model.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/ui/qt/models/coloring_rules_model.cpp b/ui/qt/models/coloring_rules_model.cpp index a13d60eacb..dced9c3774 100644 --- a/ui/qt/models/coloring_rules_model.cpp +++ b/ui/qt/models/coloring_rules_model.cpp @@ -130,6 +130,7 @@ void ColoringRulesModel::addColor(color_filter_t* colorf) beginInsertRows(QModelIndex(), count, count); ColoringRuleItem* item = new ColoringRuleItem(colorf, root_); + color_filter_delete(colorf); root_->appendChild(item); endInsertRows(); } |