File tree 1 file changed +3
-3
lines changed
Generals/Code/GameEngine/Source/GameClient/GUI/Gadget
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -202,17 +202,17 @@ static Int getListboxBottomEntry( ListboxData *list )
202
202
{
203
203
Int entry;
204
204
205
- // determin which entry is at the top of the display area
205
+ // determine which entry is at the top of the display area
206
206
for ( entry=list->endPos - 1 ; ; entry-- )
207
207
{
208
+ if ( entry < 0 )
209
+ return 0 ;
208
210
if ( list->listData [entry].listHeight == list->displayPos + list->displayHeight )
209
211
return entry;
210
212
if ( list->listData [entry].listHeight < list->displayPos + list->displayHeight && entry != list->endPos - 1 )
211
213
return entry + 1 ;
212
214
if ( list->listData [entry].listHeight < list->displayPos + list->displayHeight )
213
215
return entry;
214
- if ( entry < 0 )
215
- return 0 ;
216
216
}
217
217
218
218
return 0 ;
You can’t perform that action at this time.
0 commit comments