Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -271,8 +271,7 @@ CryptHelper::AES128Encrypt(const unsigned char *keyData, unsigned keySize, const
|
||||
BytesToKey(keyData, keySize, key, iv);
|
||||
// Add padding to plain data.
|
||||
unsigned paddedPlainSize = ADD_PADDING(plainSize);
|
||||
unsigned char *paddedPlainStr = new unsigned char[ADD_PADDING(plainSize)];
|
||||
memset(paddedPlainStr, 0, paddedPlainSize);
|
||||
unsigned char *paddedPlainStr = (unsigned char *)calloc(paddedPlainSize, 1);
|
||||
memcpy(paddedPlainStr, plainStr.c_str(), plainSize);
|
||||
// Perform the encryption.
|
||||
int cipherSize = paddedPlainSize;
|
||||
@@ -311,7 +310,7 @@ CryptHelper::AES128Encrypt(const unsigned char *keyData, unsigned keySize, const
|
||||
|
||||
gcry_cipher_close(hd);
|
||||
#endif
|
||||
delete[] paddedPlainStr;
|
||||
free(paddedPlainStr);
|
||||
}
|
||||
return retVal;
|
||||
}
|
||||
|
||||
@@ -96,10 +96,11 @@ void LocalBeRo::run()
|
||||
|
||||
PlayerListIterator it_1, it_2;
|
||||
|
||||
// running player before smallBlind
|
||||
bool formerRunningPlayerFound = false;
|
||||
if(myHand->getActivePlayerList()->size() > 2) {
|
||||
|
||||
// running player before smallBlind
|
||||
bool formerRunningPlayerFound = false;
|
||||
|
||||
it_1 = myHand->getActivePlayerIt(smallBlindPositionId);
|
||||
if(it_1 == myHand->getActivePlayerList()->end()) {
|
||||
throw LocalException(__FILE__, __LINE__, ERR_ACTIVE_PLAYER_NOT_FOUND);
|
||||
|
||||
@@ -2023,11 +2023,9 @@ void gameTableImpl::myCheck()
|
||||
int gameTableImpl::getMyCallAmount()
|
||||
{
|
||||
|
||||
int tempHighestSet = 0;
|
||||
|
||||
boost::shared_ptr<HandInterface> currentHand = myStartWindow->getSession()->getCurrentGame()->getCurrentHand();
|
||||
boost::shared_ptr<PlayerInterface> humanPlayer = currentHand->getSeatsList()->front();
|
||||
tempHighestSet = currentHand->getCurrentBeRo()->getHighestSet();
|
||||
int tempHighestSet = currentHand->getCurrentBeRo()->getHighestSet();
|
||||
|
||||
if (humanPlayer->getMyCash() + humanPlayer->getMySet() <= tempHighestSet) {
|
||||
|
||||
@@ -2065,11 +2063,10 @@ int gameTableImpl::getMyBetAmount()
|
||||
void gameTableImpl::myCall()
|
||||
{
|
||||
|
||||
int tempHighestSet = 0;
|
||||
boost::shared_ptr<HandInterface> currentHand = myStartWindow->getSession()->getCurrentGame()->getCurrentHand();
|
||||
boost::shared_ptr<PlayerInterface> humanPlayer = currentHand->getSeatsList()->front();
|
||||
|
||||
tempHighestSet = currentHand->getCurrentBeRo()->getHighestSet();
|
||||
int tempHighestSet = currentHand->getCurrentBeRo()->getHighestSet();
|
||||
|
||||
if (humanPlayer->getMyCash() + humanPlayer->getMySet() <= tempHighestSet) {
|
||||
|
||||
|
||||
@@ -15,6 +15,11 @@ public:
|
||||
void newGameStarts();
|
||||
void playSound(std::string audioString, int playerID);
|
||||
|
||||
protected:
|
||||
// Prevent copy construction.
|
||||
// This is only a declaration.
|
||||
SoundEvents(const SoundEvents &);
|
||||
|
||||
private:
|
||||
SDLPlayer *mySDLPlayer;
|
||||
ConfigFile *myConfig;
|
||||
|
||||
Reference in New Issue
Block a user