
Hello, My problem is really basic : I have N objects of type Type to store in a boost::interprocess::list<Type>. The question is easy : How many bytes should I provide to the managed_mapped_file, in order it fits correctly? So, I supposed I had to store (let's assume bi = boost::interprocess): + The list allocator : sizeof( bi::allocator<Type, bi::managed_shared_memory::segment_manager> ) + The struct of the list itself : sizeof( bi::list<Type, bi::allocator<Type, ...> > ) + The N nodes of the list containing each one of my objects : sizeof( bi::list<Type, ...>::Node) First issue : bi::list<Type, ...>::Node is private. Fine, I changed it as public. Second issue : sizeof(bi::list<Type, ...>::Node) was not enough, actually I can't add N objets, I was just able to allocate (N - x) objets Third issue : so I tried to fix the value of x, but x is not constant, it changes according to N... Thus I think, I made a mistake but where? or I forgot something but what? Thank for your help and your advises. -- View this message in context: http://www.nabble.com/boost%3Ainterprocess-sizeof%28list%3CType%3E%3A%3ANode... Sent from the Boost - Users mailing list archive at Nabble.com.