Skip to content

Commit

Permalink
Avoid use of possibly uninitialized value in CategoryListWidgetDelegate
Browse files Browse the repository at this point in the history
  • Loading branch information
phoerious authored and TheZ3ro committed Mar 3, 2018
1 parent b0a61f4 commit 8cd4d83
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/gui/CategoryListWidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,9 @@ void CategoryListWidget::emitCategoryChanged(int index)
CategoryListWidgetDelegate::CategoryListWidgetDelegate(QListWidget* parent)
: QStyledItemDelegate(parent),
m_listWidget(parent),
m_size(minWidth(), 96)
m_size(96, 96)
{
m_size.setWidth(minWidth());
if (m_listWidget && m_listWidget->width() > m_size.width()) {
m_size.setWidth(m_listWidget->width());
}
Expand Down

0 comments on commit 8cd4d83

Please sign in to comment.