Permalink
Browse files

MythUIButtonList::MoveDown: Prevent segfault when there are not enoug…

…h items

to process.
  • Loading branch information...
1 parent b379de3 commit ff9073d6805d4213472a528cd8d60d73d808321b @jpoet jpoet committed Aug 3, 2012
Showing with 2 additions and 0 deletions.
  1. +2 −0 mythtv/libs/libmythui/mythuibuttonlist.cpp
@@ -2040,6 +2040,8 @@ bool MythUIButtonList::MoveDown(MovementUnit unit, uint amount)
break;
case MoveRow:
+ if (m_itemList.empty() || m_columns < 1)
+ return true;
if (m_scrollStyle != ScrollFree)
{
m_selPosition += m_columns;

0 comments on commit ff9073d

Please sign in to comment.