Add missing PointToLocal call in mjCPlugin copy constructor.
PiperOrigin-RevId: 752486555 Change-Id: I08b14476b9098e6473a4c00918ef3f9a287f35f6
This commit is contained in:
committed by
Copybara-Service
parent
4137a4c774
commit
75f196c7ef
@@ -7271,6 +7271,8 @@ mjCPlugin::mjCPlugin(mjCModel* _model) {
|
||||
spec.plugin_name = &plugin_name;
|
||||
spec.name = &name;
|
||||
spec.info = &info;
|
||||
|
||||
PointToLocal();
|
||||
}
|
||||
|
||||
|
||||
@@ -7289,11 +7291,20 @@ mjCPlugin& mjCPlugin::operator=(const mjCPlugin& other) {
|
||||
parent = this;
|
||||
plugin_slot = other.plugin_slot;
|
||||
}
|
||||
PointToLocal();
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
|
||||
void mjCPlugin::PointToLocal() {
|
||||
spec.element = static_cast<mjsElement*>(this);
|
||||
spec.name = &name;
|
||||
spec.info = &info;
|
||||
}
|
||||
|
||||
|
||||
|
||||
// compiler
|
||||
void mjCPlugin::Compile(void) {
|
||||
mjCPlugin* plugin_instance = this;
|
||||
|
||||
Reference in New Issue
Block a user