Skip to content

Commit

Permalink
fix shm_manager use of resource conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
fengjingchao-cn authored and ycool committed Dec 20, 2017
1 parent 29d6b04 commit 039a5c0
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions ros/ros_comm/roscpp/src/libros/shm_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,15 +118,14 @@ void ShmManager::shutdown()
void ShmManager::threadFunc()
{
sharedmem_transport::SharedMemoryUtil sharedmem_util;
L_Subscription subs;
L_Subscription::iterator it;
std::string topic;

while (started_ && ros::ok())
{
if (TopicManager::instance()->getNumSubscriptions() > 0)
{
subs = TopicManager::instance()->getAllSubscription();
L_Subscription subs = TopicManager::instance()->getAllSubscription();
L_Subscription::iterator it;
if (!g_config_comm.transport_mode &&
shm_map_.size() < TopicManager::instance()->getNumSubscriptions())
{
Expand Down

0 comments on commit 039a5c0

Please sign in to comment.