* Fixes for compilation on 64-bit architectures :
  string position-returning functions return size_t, not uint.
  Fix that.
* Fixes warnings with new gcc about non-fixed string AND no arguments.

NOTE : 64-bit architectures still do not compile. There are 2 different places
where printf is used with a specifier that is not large enough on 64-bit because
size_t is now a ulong and not a uint. The solution on GNU systems is the %zu
specifier, but as I'm not sure it is supported on windows I don't want to
introduce a huge hard-to-notice bug, so I'll do it at a time when I got a
windowser to back me up.
This commit is contained in:
jean.chalard
2010-01-25 09:58:30 +00:00
parent 9b91fab61b
commit 0a083f4385
13 changed files with 48 additions and 49 deletions
+2 -2
View File
@@ -123,7 +123,7 @@ int TestSuiteAI::Act(float dt){
g->mLayers->actionLayer()->stuffHappened = 1;
}else if(action.find("p1")!=string::npos || action.find("p2")!=string::npos){
Player * p = g->players[1];
unsigned int start = action.find("p1");
size_t start = action.find("p1");
if (start != string::npos) p = g->players[0];
g->cardClick(NULL, p);
}else{
@@ -186,7 +186,7 @@ TestSuiteState::TestSuiteState(){
}
void TestSuiteState::parsePlayerState(int playerId, string s){
unsigned int limiter = s.find(":");
size_t limiter = s.find(":");
string areaS;
int area;
if (limiter != string::npos){