Archived
This forum has been archived. Please start a new discussion on GitHub.
the synchonization strategy of stl map
in Help Center
Hi all
i encountered a question relating to the synchronization of stl container, such as map, and i consulted the source of Ice with the hope of finding some hlepful informatons, but i found nothing, it's my fault because my knownledge is limited:)
could you directly tell me what strategy is adopted when the map used in Ice source is need synchonization under multithread circumstance?
forgive my poor english
thanks
i encountered a question relating to the synchronization of stl container, such as map, and i consulted the source of Ice with the hope of finding some hlepful informatons, but i found nothing, it's my fault because my knownledge is limited:)
could you directly tell me what strategy is adopted when the map used in Ice source is need synchonization under multithread circumstance?
forgive my poor english
thanks
0
Comments
-
Note that this has nothing to do with Ice, but rather is a general C++ question and thus not really covered in our free support. That being said all STL containers are strictly not thread safe -- which means that you must protect them against any concurrent access using a synchronization primitive such asa mutex otherwise you will eventually run into a problem.0