Merge remote-tracking branch 'upstream/development' into event_manager_improvements

This commit is contained in:
Robin Müller 2023-03-15 12:33:57 +01:00
commit e0a072859b
No known key found for this signature in database
GPG Key ID: 71B58F8A3CDFA9AC
2 changed files with 10 additions and 2 deletions

View File

@ -8,13 +8,18 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
# [unreleased] # [unreleased]
## Fixes
- PUS Health Service: Size check for set health command.
- PUS Health Service: Perform operation completion for announce health command.
## Added ## Added
- `EventManager`: Add function to print all listeners. - `EventManager`: Add function to print all listeners.
## Changed ## Changed
- `EventManager` queue depth is configurable now - `EventManager`: Queue depth is configurable now
# [v6.0.0] 2023-02-10 # [v6.0.0] 2023-02-10

View File

@ -82,6 +82,9 @@ ReturnValue_t CServiceHealthCommanding::prepareCommand(CommandMessage *message,
ReturnValue_t result = returnvalue::OK; ReturnValue_t result = returnvalue::OK;
switch (subservice) { switch (subservice) {
case (Subservice::COMMAND_SET_HEALTH): { case (Subservice::COMMAND_SET_HEALTH): {
if (tcDataLen != sizeof(object_id_t) + sizeof(HasHealthIF::HealthState)) {
return CommandingServiceBase::INVALID_TC;
}
HealthSetCommand healthCommand; HealthSetCommand healthCommand;
result = healthCommand.deSerialize(&tcData, &tcDataLen, SerializeIF::Endianness::BIG); result = healthCommand.deSerialize(&tcData, &tcDataLen, SerializeIF::Endianness::BIG);
if (result != returnvalue::OK) { if (result != returnvalue::OK) {
@ -93,7 +96,7 @@ ReturnValue_t CServiceHealthCommanding::prepareCommand(CommandMessage *message,
} }
case (Subservice::COMMAND_ANNOUNCE_HEALTH): { case (Subservice::COMMAND_ANNOUNCE_HEALTH): {
HealthMessage::setHealthMessage(message, HealthMessage::HEALTH_ANNOUNCE); HealthMessage::setHealthMessage(message, HealthMessage::HEALTH_ANNOUNCE);
break; return CommandingServiceBase::EXECUTION_COMPLETE;
} }
case (Subservice::COMMAND_ANNOUNCE_HEALTH_ALL): { case (Subservice::COMMAND_ANNOUNCE_HEALTH_ALL): {
ReturnValue_t result = iterateHealthTable(true); ReturnValue_t result = iterateHealthTable(true);