Corrected strict aliasing error in multiallocation_chain

[SVN r80514]
This commit is contained in:
Ion Gaztañaga committed 2012-09-13 18:54:58 +00:00
1 parent 22a18c25fb
commit 1582b2086d
5 files changed
+50 -37

No files matched your search

+2 -5
View File
@@ -589,9 +589,7 @@ class stable_vector
::value>::type * = 0)
{
while(!holder.empty()){
const node_ptr n = holder.front();
holder.pop_front();
this->deallocate_one(n);
this->deallocate_one(holder.pop_front());
}
}
@@ -1697,8 +1695,7 @@ class stable_vector
, node_ptr_traits::static_cast_from(pool_first_ref)
, node_ptr_traits::static_cast_from(pool_last_ref)
, internal_data.pool_size);
node_ptr ret = holder.front();
holder.pop_front();
node_ptr ret = holder.pop_front();
--this->internal_data.pool_size;
if(!internal_data.pool_size){
pool_first_ref = pool_last_ref = node_ptr();