Skip to content

Commit

Permalink
Ensure robot model has been loaded before processing JointState msg (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
ahoarau authored and dhood committed Apr 27, 2018
1 parent e4d1dde commit f184f1f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/rviz/default_plugin/effort_display.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,11 @@ namespace rviz
// This is our callback to handle an incoming message.
void EffortDisplay::processMessage( const sensor_msgs::JointState::ConstPtr& msg )
{
// Robot model might not be loaded already
if (!robot_model_)
{
return;
}
// We are keeping a circular buffer of visual pointers. This gets
// the next one, or creates and stores it if the buffer is not full
boost::shared_ptr<EffortVisual> visual;
Expand Down

0 comments on commit f184f1f

Please sign in to comment.