Problems with max and min in mingw

This commit is contained in:
Linus Probert 2017-12-21 12:26:57 +01:00
parent 3504dfc7d1
commit 433d907ae8
1 changed files with 4 additions and 2 deletions

View File

@ -62,19 +62,21 @@ void roommatrix_populate_from_map(RoomMatrix *rm, Map *m)
}
}
#ifndef _WIN32
#ifndef min
static int
min(int a, int b)
{
return a > b ? b : a;
}
#endif // min
#ifndef max
static int
max(int a, int b)
{
return a > b ? a : b;
}
#endif // _WIN32
#endif // max
void
roommatrix_update_with_player(RoomMatrix *rm, Player *p)