refactor(custom_robot): Remove unused method calls in destructor and stopTraj
- Deleted the Close method call for the recharge object in the CustomRobot destructor to simplify resource management. - Removed the Stop method call for the traj_th_ thread in stopTraj, streamlining the stopping process of trajectory control.
This commit is contained in:
@@ -143,7 +143,6 @@ CustomRobot::~CustomRobot() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (recharge_) {
|
if (recharge_) {
|
||||||
recharge_->Close();
|
|
||||||
recharge_.reset();
|
recharge_.reset();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -283,7 +282,6 @@ void CustomRobot::stopTraj()
|
|||||||
LOG_INFO("Stopping dynamic trajectory control...");
|
LOG_INFO("Stopping dynamic trajectory control...");
|
||||||
traj_running_ = false;
|
traj_running_ = false;
|
||||||
if (traj_th_) {
|
if (traj_th_) {
|
||||||
traj_th_->Stop();
|
|
||||||
traj_th_.reset();
|
traj_th_.reset();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user