aboutsummaryrefslogtreecommitdiff
path: root/dep/acelite/ace/Malloc_T.cpp
diff options
context:
space:
mode:
authorNay <dnpd.dd@gmail.com>2012-09-17 23:49:13 +0100
committerNay <dnpd.dd@gmail.com>2012-09-17 23:49:13 +0100
commit6568b0624dcd03243c70f9aa905b88422cb1e4c2 (patch)
tree48ec6babfbfb2f9d255df568b659db9541d11054 /dep/acelite/ace/Malloc_T.cpp
parente3add09fb7f8f3c425f6cb0e7611e4e2381bf88d (diff)
parent2e21fa6b925c4572d620248f1b149a5d652836b2 (diff)
Merge remote-tracking branch 'origin/master' into 4.3.4
Conflicts: src/server/game/Achievements/AchievementMgr.cpp src/server/game/Entities/Object/Updates/UpdateFields.h src/server/game/Entities/Unit/Unit.cpp src/server/scripts/Spells/spell_druid.cpp
Diffstat (limited to 'dep/acelite/ace/Malloc_T.cpp')
-rw-r--r--dep/acelite/ace/Malloc_T.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/dep/acelite/ace/Malloc_T.cpp b/dep/acelite/ace/Malloc_T.cpp
index 88b456d66e2..be56870f342 100644
--- a/dep/acelite/ace/Malloc_T.cpp
+++ b/dep/acelite/ace/Malloc_T.cpp
@@ -1,4 +1,4 @@
-// $Id: Malloc_T.cpp 91809 2010-09-17 07:20:41Z johnnyw $
+// $Id: Malloc_T.cpp 94341 2011-07-22 12:33:43Z schmidt $
#ifndef ACE_MALLOC_T_CPP
#define ACE_MALLOC_T_CPP
@@ -105,16 +105,17 @@ ACE_Dynamic_Cached_Allocator<ACE_LOCK>::ACE_Dynamic_Cached_Allocator
(size_t n_chunks, size_t chunk_size)
: pool_ (0),
free_list_ (ACE_PURE_FREE_LIST),
- chunk_size_(chunk_size)
+ chunk_size_ (chunk_size)
{
+ ACE_ASSERT (chunk_size > 0);
chunk_size = ACE_MALLOC_ROUNDUP (chunk_size, ACE_MALLOC_ALIGN);
- ACE_NEW (this->pool_, char[n_chunks * chunk_size_]);
+ ACE_NEW (this->pool_, char[n_chunks * chunk_size]);
for (size_t c = 0;
c < n_chunks;
c++)
{
- void* placement = this->pool_ + c * chunk_size_;
+ void *placement = this->pool_ + c * chunk_size;
this->free_list_.add (new (placement) ACE_Cached_Mem_Pool_Node<char>);
}