Exceptions are now derived from std::exception and tell source code file and line.

This commit is contained in:
lotodore
2007-10-18 20:36:49 +00:00
parent 2ba5ce4b48
commit 4c56390dc7
20 changed files with 170 additions and 147 deletions
+3 -3
View File
@@ -91,7 +91,7 @@ void LocalBeRoPreflop::run() {
it = getMyHand()->getActivePlayerIt(getSmallBlindPositionId());
if(it == getMyHand()->getActivePlayerList()->end()) {
throw LocalException(ERR_ACTIVE_PLAYER_NOT_FOUND);
throw LocalException(__FILE__, __LINE__, ERR_ACTIVE_PLAYER_NOT_FOUND);
}
if(it == getMyHand()->getActivePlayerList()->begin()) it = getMyHand()->getActivePlayerList()->end();
@@ -227,7 +227,7 @@ void LocalBeRoPreflop::run() {
PlayerListConstIterator currentPlayersTurnIt = getMyHand()->getRunningPlayerIt( getCurrentPlayersTurnId() );
if(currentPlayersTurnIt == getMyHand()->getRunningPlayerList()->end()) {
throw LocalException(ERR_RUNNING_PLAYER_NOT_FOUND);
throw LocalException(__FILE__, __LINE__, ERR_RUNNING_PLAYER_NOT_FOUND);
}
currentPlayersTurnIt++;
@@ -353,7 +353,7 @@ void LocalBeRoPreflop::run() {
currentPlayersTurnIt = getMyHand()->getRunningPlayerIt( getCurrentPlayersTurnId() );
if(currentPlayersTurnIt == getMyHand()->getRunningPlayerList()->end()) {
throw LocalException(ERR_RUNNING_PLAYER_NOT_FOUND);
throw LocalException(__FILE__, __LINE__, ERR_RUNNING_PLAYER_NOT_FOUND);
}
(*currentPlayersTurnIt)->setMyTurn(true);