Skip to content

Commit

Permalink
Actually use return value, report vocab code
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterBowman committed Mar 29, 2019
1 parent 7f85494 commit c836b94
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

#include <cmath>

#include <yarp/os/Vocab.h>

#include <ColorDebug.h>

// -----------------------------------------------------------------------------
Expand Down Expand Up @@ -130,7 +132,7 @@ bool roboticslab::BasicCartesianControl::setControlModes(int mode)

if (!iControlMode->setControlModes(jointIds.size(), jointIds.data(), modes.data()))
{
CD_WARNING("setControlModes failed.\n");
CD_WARNING("setControlModes failed (%s).\n", yarp::os::Vocab::decode(mode).c_str());
return false;
}
}
Expand Down Expand Up @@ -162,7 +164,7 @@ bool roboticslab::BasicCartesianControl::presetStreamingCommand(int command)
return false;
}

return true;
return ret;
}

// -----------------------------------------------------------------------------

0 comments on commit c836b94

Please sign in to comment.