26 Apr
2006
26 Apr
'06
6:26 p.m.
Hi Jan,
Another question! The shared memory library is great Ion Gaztañaga and others have created outstanding work.
Is a shmem container thread safe, I am assuming not but just wanted to check.
Is not thread-safe. Is exactly as thread safe as a normal STL container shared between threads. Only object construction (construction/find,) and memory allocation is thread-safe. Shmem containers are STL compliant containers capable of using advanced allocators. So if you want to insert objects in a containers from two process/threads, you need to hold a mutex first. Regards, Ion