Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,14 @@ static Int getListboxBottomEntry( ListboxData *list )
{
Int entry;

// Safety checks to prevent access violations during screen transitions
if( list == NULL )
return 0;
if( list->listData == NULL )
return 0;
if( list->endPos <= 0 )
return 0;

// determine which entry is at the top of the display area
for( entry=list->endPos - 1; ; entry-- )
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,14 @@ static Int getListboxBottomEntry( ListboxData *list )
{
Int entry;

// Safety checks to prevent access violations during screen transitions
if( list == NULL )
return 0;
if( list->listData == NULL )
return 0;
if( list->endPos <= 0 )
return 0;

// determine which entry is at the top of the display area
for( entry=list->endPos - 1; ; entry-- )
{
Expand Down