Skip to content
This repository was archived by the owner on Aug 31, 2025. It is now read-only.
Prev Previous commit
Next Next commit
actionserver: fill timestamp of goals
  • Loading branch information
aler9 committed Sep 18, 2021
commit df6132b3bde49771380a11ed388ee63e0edbb3aa
5 changes: 4 additions & 1 deletion actionserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ type ActionServerGoalHandler struct {
as *ActionServer
id string
created time.Time
stamp time.Time
state ActionServerGoalState
}

Expand Down Expand Up @@ -416,7 +417,8 @@ outer:
for id, gh := range as.goals {
ret = append(ret, actionlib_msgs.GoalStatus{
GoalId: actionlib_msgs.GoalID{
Id: id,
Stamp: gh.stamp,
Id: id,
},
Status: uint8(gh.state),
})
Expand Down Expand Up @@ -458,6 +460,7 @@ func (as *ActionServer) onGoal(in []reflect.Value) []reflect.Value {
as: as,
id: goalID.Id,
created: time.Now(),
stamp: goalID.Stamp,
}

func() {
Expand Down