diff options
-rw-r--r-- | sql/updates/world/2013_09_14_00_world_update.sql | 1 | ||||
-rw-r--r-- | sql/updates/world/2013_09_14_01_world_gobject.sql | 3 | ||||
-rw-r--r-- | src/server/scripts/Commands/cs_account.cpp | 4 | ||||
-rw-r--r-- | src/server/shared/Logging/AppenderFile.cpp | 4 | ||||
-rw-r--r-- | src/server/shared/Logging/AppenderFile.h | 3 |
5 files changed, 10 insertions, 5 deletions
diff --git a/sql/updates/world/2013_09_14_00_world_update.sql b/sql/updates/world/2013_09_14_00_world_update.sql new file mode 100644 index 00000000000..03a7515e6b3 --- /dev/null +++ b/sql/updates/world/2013_09_14_00_world_update.sql @@ -0,0 +1 @@ +UPDATE `smart_scripts` SET `target_type`=24 WHERE `entryorguid`=2935200 AND `source_type`=9 AND `id`=0 AND `link`=0; diff --git a/sql/updates/world/2013_09_14_01_world_gobject.sql b/sql/updates/world/2013_09_14_01_world_gobject.sql new file mode 100644 index 00000000000..b2b59b0d794 --- /dev/null +++ b/sql/updates/world/2013_09_14_01_world_gobject.sql @@ -0,0 +1,3 @@ +DELETE FROM `gameobject` WHERE `id`= 15885; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(99849, 15885, 1, 1, 1, 7853.95, -2212.3, 456.397, 0, 0, 0, 0, 0, 0, 0, 1); diff --git a/src/server/scripts/Commands/cs_account.cpp b/src/server/scripts/Commands/cs_account.cpp index 6fcf9dfdbec..f0d27104035 100644 --- a/src/server/scripts/Commands/cs_account.cpp +++ b/src/server/scripts/Commands/cs_account.cpp @@ -453,9 +453,9 @@ public: char* oldPassword = strtok((char*)args, " "); // This extracts [$oldpassword] char* newPassword = strtok(NULL, " "); // This extracts [$newpassword] char* passwordConfirmation = strtok(NULL, " "); // This extracts [$newpasswordconfirmation] - char* emailConfirmation = NULL; // This defines the emailConfirmation variable, which is optional depending on sec type. + const char* emailConfirmation; // This defines the emailConfirmation variable, which is optional depending on sec type. if (!(emailConfirmation = strtok(NULL, " "))) // This extracts [$emailconfirmation]. If it doesn't exist, however... - emailConfirmation = '\0'; // ... it's simply "" for emailConfirmation. + emailConfirmation = ""; // ... it's simply "" for emailConfirmation. //Is any of those variables missing for any reason ? We return false. if (!oldPassword || !newPassword || !passwordConfirmation) diff --git a/src/server/shared/Logging/AppenderFile.cpp b/src/server/shared/Logging/AppenderFile.cpp index 93d53bcc30d..54458346bb9 100644 --- a/src/server/shared/Logging/AppenderFile.cpp +++ b/src/server/shared/Logging/AppenderFile.cpp @@ -40,7 +40,7 @@ AppenderFile::~AppenderFile() void AppenderFile::_write(LogMessage const& message) { - bool exceedMaxSize = maxFileSize > 0 && (fileSize + message.Size()) > maxFileSize; + bool exceedMaxSize = maxFileSize > 0 && (fileSize.value() + message.Size()) > maxFileSize; if (dynamicName) { @@ -56,7 +56,7 @@ void AppenderFile::_write(LogMessage const& message) fprintf(logfile, "%s%s", message.prefix.c_str(), message.text.c_str()); fflush(logfile); - fileSize += message.Size(); + fileSize += uint64(message.Size()); if (dynamicName) CloseFile(); diff --git a/src/server/shared/Logging/AppenderFile.h b/src/server/shared/Logging/AppenderFile.h index c15974799e1..de94a46d692 100644 --- a/src/server/shared/Logging/AppenderFile.h +++ b/src/server/shared/Logging/AppenderFile.h @@ -19,6 +19,7 @@ #define APPENDERFILE_H #include "Appender.h" +#include "ace/Atomic_Op.h" class AppenderFile: public Appender { @@ -37,7 +38,7 @@ class AppenderFile: public Appender bool dynamicName; bool backup; uint64 maxFileSize; - uint64 fileSize; + ACE_Atomic_Op<ACE_Thread_Mutex, uint64> fileSize; }; #endif |