Skip to content

Commit 65ffd19

Browse files
committed
Add another lock guard in the set_component_state method
1 parent 017f0da commit 65ffd19

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

hardware_interface/src/resource_manager.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1597,6 +1597,7 @@ return_type ResourceManager::set_component_state(
15971597
return false;
15981598
};
15991599

1600+
std::lock_guard<std::recursive_mutex> guard(resources_lock_);
16001601
bool found = find_set_component_state(
16011602
std::bind(&ResourceStorage::set_component_state<Actuator>, resource_storage_.get(), _1, _2),
16021603
resource_storage_->actuators_);

0 commit comments

Comments
 (0)