You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In MimicJoints.cc line 70 the following if statement exists:
if(mainJointPosOpt.has_value()){
gzdbg << "Initial position of main joint found" << std::endl;
mainPos = mainJointPosOpt.value()[0];
}
There are cases in which mainJointPosOpt is of type std::optional< [std::vector]< double > > with a length of 0. The check only checks if the function was executed successfully and not if it the vector has an element at position 0. The following access leads to a segmentation fault.
Is the mainPos value essential to be set and a warning should be given if not, or is this value optional and a simple range check fix be enough here?
The text was updated successfully, but these errors were encountered:
"mainPos" is currently more or less obsolete and this piece of code can be removed accordingly. The original idea was to set joints to their correct starting position (based on their defined offset to the main joint) in line 146 but during my testing the main position component was never available during the configuration phase. This results in the mimic joints being initialized to their offset without considering the main joint initial position.
In MimicJoints.cc line 70 the following if statement exists:
if(mainJointPosOpt.has_value()){
gzdbg << "Initial position of main joint found" << std::endl;
mainPos = mainJointPosOpt.value()[0];
}
There are cases in which mainJointPosOpt is of type std::optional< [std::vector]< double > > with a length of 0. The check only checks if the function was executed successfully and not if it the vector has an element at position 0. The following access leads to a segmentation fault.
Is the mainPos value essential to be set and a warning should be given if not, or is this value optional and a simple range check fix be enough here?
The text was updated successfully, but these errors were encountered: