Gazebo | Ignition | Community
Ask Your Question

Revision history [back]

Is there a mutex that guarantees a link pointer will remain valid?

If I want to call a function of a LinkPtr, I need to ensure it's not-null, and a simple if-statement is not sufficient if the LinkPtr is being access or potentially deleted from other threads. Would locking the physicsUpdateMutex protect me from this? if not, is there a different mutex I can use?