Commit Graph

74 Commits

Author SHA1 Message Date
Machiavelli
c4e4486903 Properly deregister WorldSocket connections in case of reaching socket timeout time.
--HG--
branch : trunk
2010-04-23 12:56:16 +02:00
n0n4m3
be95faff23 Fix mail, professions, group loot, console spam, and some fixes. Big thx to TOM_RUS.
--HG--
branch : trunk
2010-04-11 11:16:42 +04:00
Spp
49d05ba9aa Code style (game + scripts only):
"( " --> "("
" )" --> ")"

--HG--
branch : trunk
2010-04-07 22:59:46 +02:00
Spp
d19e127080 Code style (game + scripts only):
"if(" --> "if ("

--HG--
branch : trunk
2010-04-07 19:14:10 +02:00
Spp
b27ce42704 Code Style: Remove trailing spaces
--HG--
branch : trunk
2010-04-07 18:09:10 +02:00
Machiavelli
ce2d71e1d9 Add config option that determines the maximum allowed time between the last received CMSG_CHAR_ENUM and another incoming packet, and will disconnect the peer if this time limit is exceeded.
In other words, a time limit in which idlers can stay logged in on the character selection screen before they are disconnected.
Fixes issue #335

--HG--
branch : trunk
2010-02-12 19:59:44 +01:00
Anubisss
d9cb070215 Implement QueryResult_AutoPtr type which is ACE's reference counted auto_ptr(ACE_Refcounted_Auto_Ptr) for QueryResult pointers.
Use this auto_ptr for every DB queries(except QueryNamedResult yet).

This patch guarantees NO memory leaks from QueryResult pointers.

Thanks to raczman for the idea and for the helping to make this patch.

--HG--
branch : trunk
2010-01-23 14:45:58 +01:00
n0n4m3
99f66a6bc9 Updated copyright for new year.
--HG--
branch : trunk
2010-01-16 20:19:18 +03:00
QAston
c65aa45bc6 *Tabs to spaces
*Fix a type in CreatureEventAI.cpp from last rev

--HG--
branch : trunk
2010-01-10 02:12:02 +01:00
p0wer
b4e1ee6355 Fix some whitespace errors. Corrected account_access 'id' type.
--HG--
branch : trunk
2009-12-21 21:21:39 -06:00
p0wer
7590479186 * Add support for different gmlevel's for different realms.
*
* Using the value -1 will add the same value for all realms.
* Make sure to apply the updates.
* Information regarding this patch will be posted on the database forums soon.
*
* Thanks to Sundark and the Ilixiuemu team(for original patch)

--HG--
branch : trunk
2009-12-21 21:08:29 -06:00
maximius
dc1207139a *Cleanup, proper indentation, and remove some wrong/irrelevant comments copied from custom patches..
--HG--
branch : trunk
2009-12-18 13:41:30 -08:00
n0n4m3
f20b25d1c9 Update some code for 322a
--HG--
branch : trunk
2009-12-17 12:36:55 +01:00
Rat
40dceb43d6 *fix Character freeze after map change or login. Closes #19 patch by trazom
--HG--
branch : trunk
2009-11-10 10:16:26 +01:00
maximius
3f338cc1c3 *Massive cleanup redux.
--HG--
branch : trunk
2009-10-17 16:20:24 -07:00
maximius
e585187b24 *Backed out changeset 3be01fb200a5
--HG--
branch : trunk
2009-10-17 15:51:44 -07:00
maximius
26b5e033ff *Massive cleanup (\n\n -> \n, *\n -> \n, cleanup for(...) to for (...), and some other cleanups by hand)
*Fix a possible crash in Spell::DoAllEffectOnTarget

--HG--
branch : trunk
2009-10-17 15:35:07 -07:00
Chaz Brown
f9a9bbed7b Backed out changeset 5da05b39c3eb
Causes crashes on Linux.

--HG--
branch : trunk
2009-09-27 17:28:57 -04:00
Chaz Brown
a635bdd0cc * Fix Player getting stuck after teleport, etc. due to high number of achievements - patch by Trazom
http://www.trinitycore.org/forum/project.php?issueid=4329&page=4#note34721

--HG--
branch : trunk
2009-09-27 02:13:56 -04:00
maximius
6c46fc09b0 *Cleanup + Fix Linux build by WarHead
--HG--
branch : trunk
2009-09-19 16:21:10 -07:00
maximius
333f1c9d72 *[8475] fixed some gcc-warnings Author: balrok
*[8476] Revert some recent cleanup changes, some other fixes and cleanups. Author: VladimirMangos
*[8489] Fixed player visibility update in case view point different from player itself. Author: SilverIce
*[8493] Avoid unexpected multiply error messages at wrong `quest_template`.`RewSpell*` Author: VladimirMangos
*[8496] Resolve some #include cycles and unsafe code.
* Common.h -> Threading.h -> Errors.h -> Common.h
* Remove reduncdent #include "ByteBuffer.h" in headers
* Remove redundent #include "Auth/BigNumber.h" in headers
* Avoid multyply data copy at use some now dropped functions in BigNumber.
* Avoid copy fixed byte count from byte arrays with unknown real size created from BigNumber.
* Avoid possible problems for build mangos at different platform or compilers. Author: VladimirMangos.
*[8501] Apply code style and cleanups to some Player functions. Author: VladimirMangos.
*[8502] Disable quests related to specific game events at startup if event not active. Also rename member boolean variable. Author: NoFantasy
*[8506] Add check for IsAutoComplete() in SendPreparedQuest().
For cases where quest is repeatable but has Method!=0, QuestDetails must be sent instead of RequestItems.
Some additional code cleanup. Author: NoFantasy
*[8507] Check amount of spawned pools before decrement to avoid unexpected result. Also rename variable to more meaningful name. Signed-off-by: NoFantasy <nofantasy@nf.no>

Thanks to Stryker and onkelz28!

--HG--
branch : trunk
2009-09-18 14:10:37 -07:00
megamage
ea12ff233b [8450] Prevented using of plaintext passwords in sql queries Author: arrai
--HG--
branch : trunk
2009-09-02 18:14:10 -05:00
megamage
790c5348a3 [8445] Fixed redundant calculation of v and s on every login Author: arrai
The SRP-6 specifications clearly say, that v and s are only to be
    calculated on registering a user and changing his password; calculating
    them on every login is plain waste.

--HG--
branch : trunk
2009-09-02 16:22:32 -05:00
megamage
dc68c2b269 [8433] Implement proper store and use character specific account data.
* Base at TOM_RUS reseach save/load character specific account data in new table `character_account_data`
    * Move its in sql update from `account_data` to new table.
    * For client packets that can be send in loggined state or just after logout but assocualted
      with recently logout character add new login status STATUS_LOGGEDIN_OR_RECENTLY_LOGGOUT
    * Store low guid for loggedin player or recently logout into WorldSession.

Author: VladimirMangos, TOM_RUS

--HG--
branch : trunk
2009-09-01 16:47:49 -05:00
Chaz Brown
055acc4b8a Replace switch with more proper way of checking allowSecurityLevel, and a few other minor changes.
--HG--
branch : trunk
2009-08-29 08:51:24 -04:00
megamage
c911772125 [8389] Implement check really read received packet size and warning it not all data read. Author: VladimirMangos
* This let more easy catch packet structure chnages at client switch.
    * Fixed structure CMSG_GUILD_BANK_SWAP_ITEMS
    * Fixed structure CMSG_SPLIT_ITEM, CMSG_SELL_ITEM
    * Added read data amount fixes for some other packets.

    Thanks to TOM_RUS in help check correct packets structure.

    Note: not all packets possible fixed. Please report for not fixed cases at errors:
    "opcode %s (0x%.4X) have unprocessed tail data (read stop at %u from %u)"

--HG--
branch : trunk
2009-08-19 17:07:21 -05:00
megamage
e954904e6d [8378] Use exceptions instead of explicit size checking for each packet Author: arrai
CHECK_PACKET_SIZE was pretty error prone; once it was forgotten mangosd
    could crash due to the asserts in ByteBuffer.h. That was exploitable by
    malicious players.
    Furthermore, there were duplicate checks: Additionally to
    CHECK_PACKET_SIZE, the ByteBuffer assertions keept an eye
    on not exceeding the packet boundaries - just to crash the server for
    sure in such a case.
    To prevent memory leaks or other undesirable states, please read in
    every handler all variables _before_ doing any concrete handling.

--HG--
branch : trunk
2009-08-19 16:26:22 -05:00
megamage
ccd6764409 [8278] Update packet size checks in WorldSocket::HandleAuthSession to 3.x state. Author: VladimirMangos
--HG--
branch : trunk
2009-07-31 11:37:31 +08:00
megamage
ed995581af *Fixed /played chat command. Author: tomrus88
--HG--
branch : trunk
2009-07-31 11:33:48 +08:00
megamage
0fcadd9d25 *Replace "LoginDatabase" with "loginDatabase"
--HG--
branch : trunk
2009-07-31 11:29:28 +08:00
megamage
447453f4d4 *Fix a bug that client cannot log in.
--HG--
branch : trunk
2009-06-12 21:59:55 -05:00
megamage
9d670fe6f5 *Switch to support client version 3.1.3
*I strongly recommend you not to use this until you get the 313 db. Now all destructible buildings cause client crash.

Source: Mangos
Thanks to TOM_RUS for most work to make this switch possible ;)

--HG--
branch : trunk
2009-06-11 00:45:59 -05:00
megamage
9381493a64 [7878] Use bigger buf for better performence. Author: Derex
--HG--
branch : trunk
2009-05-24 11:10:55 -05:00
megamage
21fa39edd4 *Revert Mangos [7022] to see if this can fix the cpu spikes in Windows.
--HG--
branch : trunk
2009-04-29 16:15:15 -05:00
megamage
295b634ca6 [7731] Some code cleanups, warrning fixes. Author: VladimirMangos
--HG--
branch : trunk
2009-04-29 00:31:03 -05:00
megamage
28359b3ea8 *Fix the format of world log.
--HG--
branch : trunk
2009-04-25 08:59:18 -05:00
Chaz Brown
1895373af4 fix a long standing typo
--HG--
branch : trunk
2009-04-06 00:12:13 -04:00
XTZGZoReX
e63adf5a29 * Allow use security > 3 in realmd.account.gmlevel field. This will fix issue where gmlevels above 3 did not work.
* Note: Have in mind that gmlevels above 3 can have "unexpected" effects; players with, for example, gmlevel 4 _may_ be able to execute console-only commands from ingame.

--HG--
branch : trunk
2009-04-05 00:04:10 +02:00
megamage
de849cc508 Small code cleanup and partial merge with dev branch Author: tomrus88
--HG--
branch : trunk
2009-03-21 14:53:38 -06:00
megamage
f1afff1a5b Updated OpenSSL lib. Thanks to Neo2003. Author: tomrus88
--HG--
branch : trunk
2009-03-21 14:39:04 -06:00
XTZGZoReX
28c03b77ad * Fixed way too many \n in WorldLog output.
--HG--
branch : trunk
2009-03-21 18:35:59 +01:00
XTZGZoReX
55695eda78 * Implement ".server set closed on/off" command to allow/deny new connections to the world.
--HG--
branch : trunk
2009-03-21 13:51:28 +01:00
XTZGZoReX
3c713189fb * Correctly implement database logging in WorldLog.
* This fixes LogDB.World config option.

--HG--
branch : trunk
2009-03-19 21:28:25 +01:00
megamage
3d3656297f [7424] Codestyle: removed not needed \n in log output. Author: balrok
--HG--
branch : trunk
2009-03-09 17:56:51 -06:00
megamage
699bc588b8 [7330] Code warnings and style cleanups. Some bugs fixes. Author: VladimirMangos
1) comparison singed and unsigned values
    2) redundent includes
    3) wrong constructor :-part field initilization
    4) unused not-/*name*/-guarded args in template/virtual functions that not required like args.
    5) explicitly list not implemented achievement types.

    Also bugs fixed:
    1) Drop wrong phase mask 0 check in WorldObject::InSamePhase.
    2) ArenaTeamMember::ModifyPersonalRating incorrect work with move points in negative with infinity values in result.
    3) ArenaTeam::SaveToDB code send uint64 value to string with arg format %u.

--HG--
branch : trunk
2009-02-24 11:14:28 -06:00
megamage
31637d4aac *Merge.
--HG--
branch : trunk
2009-02-18 11:36:19 -06:00
KingPin
14234c86fa Newline added to bottom of all files.
--HG--
branch : trunk
2009-02-17 20:07:49 -06:00
megamage
4d008f2043 Replace tabs with spaces, and fix crlf issues
--HG--
branch : trunk
2009-02-04 10:33:18 -06:00
megamage
d69198732e *Merge.
--HG--
branch : trunk
2009-02-04 17:22:43 -06:00
megamage
df7499e056 *Merge.
--HG--
branch : trunk
2009-02-04 10:53:58 -06:00