c++ - boost::shared_mutex vs boost::mutex for multiple threads writing? -


i have scenario multiple threads writing common buffer (a map), each thread or not have same key. can please advise on whether should use boost::shared_mutex or boost::mutex? understanding boost::shared_mutex single writer , multiple reads not want. make boost::mutex more appropriate scenario?

thanks in advance

yes, boost::shared_mutex not case don't have pure readers , have multiple writers. use boost::mutex enforce exclusive access shared data.


Comments

Popular posts from this blog

javascript - CasperJS/PhantomJS failing SSL handshakes on some sites even with --ssl-protocol=any -

codeigniter - Fatal error: Call to undefined function lang() in CI Merchant using CardSave -

python - Received unregistered task using Celery with Django -