Changeset - r2992:bad4190a8564
[Not reviewed]
master
0 1 0
Darkvater - 18 years ago 2006-02-06 23:28:07
darkvater@openttd.org
(svn r3568) - Fix: constantizing side-effect of qsort in r3563. Ugly? Yes. Makes MSVC happy? Yes.
1 file changed with 1 insertions and 1 deletions:
0 comments (0 inline, 0 general)
players.c
Show inline comments
 
@@ -1021,13 +1021,13 @@ int8 SaveHighScoreValueNetwork(void)
 
	const Player* pl[MAX_PLAYERS];
 
	size_t count = 0;
 
	int8 player = -1;
 

	
 
	/* Sort all active players with the highest score first */
 
	FOR_ALL_PLAYERS(p) if (p->is_active) pl[count++] = p;
 
	qsort(pl, count, sizeof(pl[0]), HighScoreSorter);
 
	qsort((Player*)pl, count, sizeof(pl[0]), HighScoreSorter);
 

	
 
	{
 
		uint i;
 

	
 
		memset(_highscore_table[LAST_HS_ITEM], 0, sizeof(_highscore_table[0]));
 

	
0 comments (0 inline, 0 general)