[Pool] pool_allocator with vector-of-vectors ??

12 Jun
2007
12 Jun
'07
9:30 p.m.
I have a question about using the standard allocator interface in the boost.pool library. (I'm using boost 1.34.0 with g++ 3.4.3 on redhat linux, in case it matters.) I've successfully used boost::pool_allocator with individual std::vector objects, but I'm having trouble using it with a vector-of-vectors object, like this: std::vector<std::vector<int, boost::pool_allocator<int> > > myvec(1); myvec[0].push_back(99); The "push_back" line causes a seg-fault, which purify says is an array-bounds-write occurring in boost::simple_segregated_storage<unsigned long>::segregate. Am I misusing the pool_allocator? Thanks, Alan
6555
Age (days ago)
6555
Last active (days ago)
0 comments
1 participants
participants (1)
-
Williams, Alan B