more defensive buffer handling
Some checks failed
EIVE/eive-obsw/pipeline/head There was a failure building this commit

This commit is contained in:
2022-08-15 18:53:25 +02:00
parent 458929957d
commit 232372fd96
6 changed files with 19 additions and 14 deletions

View File

@ -19,6 +19,8 @@ PlocMPSoCHandler::PlocMPSoCHandler(object_id_t objectId, object_id_t uartComIFid
eventQueue = QueueFactory::instance()->createMessageQueue(EventMessage::EVENT_MESSAGE_SIZE * 5);
commandActionHelperQueue =
QueueFactory::instance()->createMessageQueue(EventMessage::EVENT_MESSAGE_SIZE * 5);
spParams.maxSize = sizeof(commandBuffer);
spParams.buf = commandBuffer;
}
PlocMPSoCHandler::~PlocMPSoCHandler() {}
@ -207,8 +209,6 @@ ReturnValue_t PlocMPSoCHandler::buildCommandFromCommand(DeviceCommandId_t device
const uint8_t* commandData,
size_t commandDataLen) {
spParams.buf = commandBuffer;
spParams.maxSize = sizeof(commandBuffer);
ReturnValue_t result = RETURN_OK;
switch (deviceCommand) {
case (mpsoc::TC_MEM_WRITE): {