src/gui/channellist.cpp fix possible segfault after edit mode (heap-buffer-overflow)

Origin commit data
------------------
Branch: ni/coolstream
Commit: d6246131d2
Author: Jacek Jendrzej <overx300@gmail.com>
Date: 2015-12-19 (Sat, 19 Dec 2015)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Jacek Jendrzej
2015-12-19 20:18:49 +01:00
parent 53033a8af0
commit 68b7808b16

View File

@@ -1850,6 +1850,9 @@ void CChannelList::paintItem(int pos, const bool firstpaint)
iscurrent = SameTP((*chanlist)[curr]);
}
if(selected >= (*chanlist).size())
selected = (*chanlist).size()-1;
if (curr == selected) {
color = COL_MENUCONTENTSELECTED_TEXT;
bgcolor = COL_MENUCONTENTSELECTED_PLUS_0;