Correct use of uninitialized value and clean up FullInertia function
PiperOrigin-RevId: 605049375 Change-Id: I7ffb6bd56b08111036e8490bf767fb9393499f13
This commit is contained in:
committed by
Copybara-Service
parent
ea69f20b43
commit
e4fada1963
+2
-1
@@ -266,7 +266,8 @@ void mjXURDF::Body(XMLElement* body_elem) {
|
||||
|
||||
// process inertia
|
||||
// lquat = rotation from specified to default (joint/body) inertial frame
|
||||
double lquat[4], tmpquat[4];
|
||||
double lquat[4] = {1, 0, 0, 0};
|
||||
double tmpquat[4] = {1, 0, 0, 0};
|
||||
const char* altres = mjm_setFullInertia(pbody, lquat, pbody->inertia);
|
||||
|
||||
// inertia are sometimes 0 in URDF files: ignore error in altres, fix later
|
||||
|
||||
Reference in New Issue
Block a user