raczman
ba22baebbd
Core/Auth: Implement time-based token for user login as described in RFC 6238.
...
New column in account table is a base32 of token key bytes,
coincidentally it is the same format Google's Authenticator Android app uses.
If you want that to work, set system time on server correctly and use ntpd.
Closes #10527
Signed-off-by: Nay <dnpd.dd@gmail.com >
2013-08-25 14:02:40 +01:00
jackpoz
e96aa444b0
Core/Threading: Fix race condition in Thread
...
Increment the reference count of m_task in Thread::start() before spawning the actual Thread that will execute the task, otherwise the thread might finish, decRef the task and delete it.
Valgrind log of the issue:
Invalid read of size 8
at 0x1314CAD: ACE_Atomic_Op_GCC<long>::operator++() (Atomic_Op_GCC_T.inl:34)
by 0x15933FB: ACE_Based::Runnable::incReference() (Threading.h:36)
by 0x1592D2D: ACE_Based::Thread::start() (Threading.cpp:136)
by 0x1592C37: ACE_Based::Thread::Thread(ACE_Based::Runnable*) (Threading.cpp:111)
by 0xF6C463: Master::Run() (Master.cpp:195)
by 0xF725D0: main (Main.cpp:142)
Address 0x26137278 is 8 bytes inside a block of size 24 free'd
at 0x4C2B59C: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
by 0xF67FDB: RARunnable::~RARunnable() (RARunnable.cpp:55)
by 0x1593441: ACE_Based::Runnable::decReference() (Threading.h:40)
by 0x1592E92: ACE_Based::Thread::ThreadTask(void*) (Threading.cpp:186)
by 0x515EA35: ACE_OS_Thread_Adapter::invoke() (in /usr/lib/libACE-6.0.3.so)
by 0x5F19F8D: start_thread (pthread_create.c:311)
by 0x6A46E1C: clone (clone.S:113)
Closes #10619
2013-08-25 13:48:55 +01:00
Nay
12973de799
Core&Tools: Fix multiple issues found by a static code coverage tool
2013-08-24 22:57:22 +01:00
jackpoz
21459739c6
Fix uninitialized UpdateMask field
...
Initialized UpdateMask::_bits to NULL in all constructors.
UpdateMask(UpdateMask const& right) constructor sets the field count with SetCount() method before any field initialization. This means that SetCount() will call delete[] on the uninitialized _bits pointer field, leading to undefined behavior.
2013-08-24 17:49:14 +02:00
Nay
58e6503eef
Core/Settings: Fix build in non cpp11 compilers
...
std::string back() was only introduced in C++11, a pity..
2013-08-24 15:45:19 +01:00
Nay
cc3055f344
Core/Settings: Fix a crash if worldserver.conf DataDir setting is empty
2013-08-24 14:30:17 +01:00
Nay
0d5181af4d
Merge pull request #10559 from Discover-/Taxi-Benchmarking
...
Core/Misc: Implement CMSG_SET_TAXI_BENCHMARK_MODE to toggle PLAYER_FLAGS...
2013-08-23 17:57:21 -07:00
Nay
a0a377a0ce
Scripts: Fix two issues found by Valgrind
...
==3400== Invalid write of size 8
==3400== at 0x1241C32: instance_ahnkahet::GetInstanceScript(InstanceMap*) const (instance_ahnkahet.cpp:54)
...
==3400== Conditional jump or move depends on uninitialised value(s)
==3400== at 0xB5DEAE: std::tr1::_Hashtable<unsigned long, std::pair<unsigned long const, Creature*>, std::allocator<std::pair<unsigned long const, Creature*> >, std::_Select1st<std::pair<unsigned long const, Creature*> >, std::equal_to<unsigned long>, std::tr1::hash<unsigned long>, std::tr1::__detail::_Mod_range_hashing, std::tr1::__detail::_Default_ranged_hash, std::tr1::__detail::_Prime_rehash_policy, false, false, true>::_M_find_node(std::tr1::__detail::_Hash_node<std::pair<unsigned long const, Creature*>, false>*, unsigned long const&, unsigned long) const (hashtable.h:830)
==3400== by 0xBDA4CA: std::tr1::_Hashtable<unsigned long, std::pair<unsigned long const, Creature*>, std::allocator<std::pair<unsigned long const, Creature*> >, std::_Select1st<std::pair<unsigned long const, Creature*> >, std::equal_to<unsigned long>, std::tr1::hash<unsigned long>, std::tr1::__detail::_Mod_range_hashing, std::tr1::__detail::_Default_ranged_hash, std::tr1::__detail::_Prime_rehash_policy, false, false, true>::find(unsigned long const&) (hashtable.h:698)
==3400== by 0xBDA5BF: HashMapHolder<Creature>::Find(unsigned long) (ObjectAccessor.h:67)
==3400== by 0xCB5C03: Map::GetCreature(unsigned long) (ObjectAccessor.h:114)
==3400== by 0xB6E6EF: Unit::GetCreature(WorldObject&, unsigned long) (Unit.cpp:13023)
==3400== by 0x10F0790: boss_hydross_the_unstable::boss_hydross_the_unstableAI::Reset() (boss_hydross_the_unstable.cpp:164)
2013-08-24 01:54:37 +01:00
Shauren
da693bbc81
Scripts/Halls of Reflection: Fixed accessing uninitialized memory
2013-08-23 18:45:17 +02:00
Aokromes
b5362c5c45
Script/Ahnkahet: Fix warning
2013-08-23 14:47:38 +02:00
joschiwald
99081bcf54
Merge branch 'master' of github.com:TrinityCore/TrinityCore
2013-08-22 13:48:47 +02:00
joschiwald
8e833743d4
Scripts/GruulsLair: reworked InstanceScript
...
Known Issue: position desynch after creature respawn
2013-08-22 13:47:54 +02:00
Vincent-Michael
dc86e87f25
Scripted/ShadeOfAkama: Some cleanups
2013-08-21 19:58:12 +02:00
joschiwald
a383885f5c
Scripts/AhnKahet: reworked InstanceScript
2013-08-21 19:43:46 +02:00
Vincent-Michael
1e89ae1960
Core: Fix warnings and random changes
2013-08-21 18:46:52 +02:00
joschiwald
62c7e309ee
Scripts/BlackTemple: reworked InstanceScript
2013-08-21 12:29:28 +02:00
joschiwald
7a14e366ac
Scripts/AzjolNerub: reworked InstanceScript
2013-08-20 23:05:00 +02:00
Shauren
296da5df12
Core/Commands: Improved debug moveflags to also send associated opcodes
2013-08-20 21:16:54 +02:00
joschiwald
7e3a52bb42
Scripts/HallsOfLightning: reworked InstanceScript
2013-08-20 18:11:41 +02:00
Shauren
75cc4e7b25
Core/Auras
...
* Fixed unsafe removal of charm auras, it is now safe to remove them inside AI hooks
* Fixes crash in SmartAI::EnterEvadeMode
Closes #8679
2013-08-20 00:43:03 +02:00
Shauren
44485a74ad
Scripts/Icecrown Citadel: Fixed Ice Tomb targeting tanks in phase 3 in Sindragosa encounter
...
Closes #8778
2013-08-19 22:16:05 +02:00
joschiwald
e0f010b310
Scripts: Random script fixes and code optimizations
2013-08-19 20:03:06 +02:00
Vincent-Michael
7679145da5
Core: Fix warning
2013-08-19 15:04:45 +02:00
QAston
dedeb5f9eb
Fix build with gcc. Thanks to McBitter for testing.
2013-08-19 14:52:17 +02:00
QAston
0513d9c8d0
Core: Fix warnings. Make callback symbols local.
2013-08-18 20:30:38 +02:00
QAston
19343ddd55
Fix crashed caused by using openssl from multiple threads simultanously.
...
Note that this doesn't make BigNumber class threadsafe - it never was that way.
2013-08-18 17:44:04 +02:00
QAston
2a3370929d
Fix BigNumber::AsByteArray function by returning Auto_Ptr.
...
Remove mutex from BigNumber class - it didn't do what it was advertised to do - consider using the "locked" array outside of the function in which it was "locked".
2013-08-18 17:44:03 +02:00
QAston
8160633e12
Core: Fix a bug in BigNumber::SetBinary
2013-08-18 17:44:02 +02:00
QAston
10fb50ad66
Core: Fix a bug in BigNumber::SetQword
2013-08-18 17:44:02 +02:00
Shauren
6a55395e4f
Core/Players: Do not add banned characters to _legitCharacters container
2013-08-18 15:23:39 +02:00
Vincent-Michael
9eb01d63bd
Core: Fix warnings
2013-08-18 13:54:20 +02:00
Vincent-Michael
7dbf68cbfc
Scripted/Misc: Remove some whitespace
2013-08-18 02:07:13 +02:00
joschiwald
2b19ba1879
Misc: replace Unit::GetPlayer with ObjectAccessor::GetPlayer and some cosmetic changes
2013-08-18 01:41:10 +02:00
Vincent-Michael
c32dbd1432
Core/Spells: Fix hunter T7 4P Bonus
...
Closes #8320
2013-08-18 00:55:44 +02:00
Vincent-Michael
da1e466bd5
Core/Misc: Implemented GetObjectScale function
2013-08-17 23:47:43 +02:00
w1sht0l1v3
1ad954e215
Core/Scripts: Placeholders for instances Maraudon and Dire Maul.
...
It is needed for Random Dungeon Finder credit.
2013-08-17 19:14:48 +03:00
w1sht0l1v3
7c7f19228e
Core/Scripts: Placeholders for instances The Slave Pens and The Underbog.
...
It is needed for Random Dungeon Finder credit.
2013-08-17 17:50:33 +03:00
w1sht0l1v3
0333d22fe9
Core/Scripts: Placeholder for instance Ragefire Chasm.
...
It is needed for Random Dungeon Finder credit.
2013-08-17 15:25:09 +03:00
Discover-
77f1d3a328
Core/Misc: Implement CMSG_SET_TAXI_BENCHMARK_MODE to toggle PLAYER_FLAGS_TAXI_BENCHMARK based on arguments. To enable/disable this, call '/script SetTaxiBenchmarkMode(1)' (1 = on, 0 = off). Basically debugs the taxi flight and outputs min, max and avg FPS during flight. Automatically toggled off when flight ends.
2013-08-17 14:17:38 +02:00
w1sht0l1v3
7b9f34afc5
Core/Scripts: Placeholder for instance The Stockade.
...
It is needed for Random Dungeon Finder credit.
Correct entry for last encounter in the instance.
2013-08-17 14:59:49 +03:00
joschiwald
c45e665c86
Core/Spells: move spell resistance calculation into separate function (and some cosmetic changes)
...
Ref #7254
2013-08-17 00:47:44 +02:00
MitchesD
90dcb2a448
Scripts/DrakTharonKeep: update Tharon'Ja
...
- update Tharon Ja to BossAI
- update one creature - cosmetic npc
Closes #10524
2013-08-16 14:34:42 +02:00
betagan
c81c198d4c
Core/Spells: Fix deathknight gladiator glove bonus
...
Closes #512
2013-08-16 02:50:47 +02:00
Shauren
4d260a54ae
Core/Spells: Fixed warrior T10 4p dps bonus
...
Closes #493
2013-08-15 16:39:31 +02:00
Shauren
a647d3590c
Core/Spells: Fixed Execute rolling for procs twice
2013-08-15 16:38:35 +02:00
Shauren
c52f9aa315
Core/Spells: Refactored SpellInfo::CalcCastTime() to prevent accidental mod charge losses caused by its incorrect usage
2013-08-15 16:37:18 +02:00
Shauren
d1bb6da668
Core/Spells: Fixed cast time mods using two charges on every cast
2013-08-15 16:34:57 +02:00
Shauren
2ac6380202
Core/Auras: Allow preventing whole aura proc default handler from script hooks, just how it is possible for separate effects
2013-08-15 16:32:22 +02:00
Discover-
a0ff0233c5
Core/SmartAI: Implement SMART_TARGET_CLOSEST_FRIENDLY.
...
Parameter is distance to search for.
Closes #10521
2013-08-15 01:22:22 +01:00
Discover-
8c961687a0
Core/SmartAI: Implement SMART_EVENT_FRIENDLY_HEALTH_PCT.
...
On current clean TDB, there are a total of 106 creatures using
SMART_EVENT_FRIENDLY_HEALTH (non-PCT) which has a flat first parameter, but
only 8 of these use the event correctly (and therefore only 8 of them
actually work).
Closes #10520
2013-08-15 01:18:10 +01:00