- cleanup of last compiler warnings in Linux (hurray!)

This commit is contained in:
Mark Vejvoda 2010-10-21 18:24:54 +00:00
parent ba088e9258
commit 79318735ab
3 changed files with 3 additions and 3 deletions

View File

@ -386,7 +386,7 @@ TravelState PathFinder::aStar(Unit *unit, const Vec2i &targetPos, bool inBailout
std::pair<Vec2i,Chrono> lastHarvest = unit->getLastHarvestResourceTarget();
char szBuf[1024]="";
sprintf(szBuf,"State: blocked, cmd [%s] pos: [%s], dest pos: [%s], lastHarvest = [%s - %lld], reason A= %d, B= %d, C= %d, D= %d, E= %d, F = %d",commandDesc.c_str(),unit->getPos().getString().c_str(), targetPos.getString().c_str(),lastHarvest.first.getString().c_str(),lastHarvest.second.getMillis(), pathFound,(lastNode == firstNode),path->getBlockCount(), path->isBlocked(), nodeLimitReached,path->isStuck());
sprintf(szBuf,"State: blocked, cmd [%s] pos: [%s], dest pos: [%s], lastHarvest = [%s - %lld], reason A= %d, B= %d, C= %d, D= %d, E= %d, F = %d",commandDesc.c_str(),unit->getPos().getString().c_str(), targetPos.getString().c_str(),lastHarvest.first.getString().c_str(),(long long int)lastHarvest.second.getMillis(), pathFound,(lastNode == firstNode),path->getBlockCount(), path->isBlocked(), nodeLimitReached,path->isStuck());
unit->setCurrentUnitTitle(szBuf);
}

View File

@ -721,7 +721,7 @@ void ClientInterface::waitUntilReady(Checksum* checksum) {
lastMillisCheck = (chrono.getMillis() / 1000);
char szBuf[1024]="";
sprintf(szBuf,"Waiting for network: %lld seconds elapsed (maximum wait time: %d seconds)",lastMillisCheck,int(readyWaitTimeout / 1000));
sprintf(szBuf,"Waiting for network: %lld seconds elapsed (maximum wait time: %d seconds)",(long long int)lastMillisCheck,int(readyWaitTimeout / 1000));
logger.add(szBuf, true);
}
}

View File

@ -106,7 +106,7 @@ string boolToStr(bool b){
string intToStr(int64 i) {
char str[strSize]="";
sprintf(str, "%lld", i);
sprintf(str, "%lld", (long long int)i);
return str;
}