small fix for persistent TM store
Some checks are pending
EIVE/eive-obsw/pipeline/head Build queued...
EIVE/eive-obsw/pipeline/pr-main This commit looks good

This commit is contained in:
2023-06-29 01:28:40 +02:00
parent 109856eef8
commit ad3c0e2a0e
4 changed files with 34 additions and 16 deletions

View File

@ -128,6 +128,7 @@ ReturnValue_t PersistentTmStore::assignAndOrCreateMostRecentFile() {
ReturnValue_t PersistentTmStore::handleCommandQueue(StorageManagerIF& ipcStore,
Command_t& execCmd) {
execCmd = CommandMessageIF::CMD_NONE;
CommandMessage cmdMessage;
ReturnValue_t result = tcQueue->receiveMessage(&cmdMessage);
if (result != returnvalue::OK) {
@ -162,9 +163,9 @@ ReturnValue_t PersistentTmStore::handleCommandQueue(StorageManagerIF& ipcStore,
result = startDumpFromUpTo(dumpFromUnixSeconds, dumpUntilUnixSeconds);
if (result == BUSY_DUMPING) {
triggerEvent(persTmStore::BUSY_DUMPING_EVENT);
} else {
execCmd = cmd;
return result;
}
execCmd = cmd;
}
}
return result;
@ -359,7 +360,10 @@ ReturnValue_t PersistentTmStore::loadNextDumpFile() {
}
ReturnValue_t PersistentTmStore::getNextDumpPacket(PusTmReader& reader, bool& fileHasSwapped) {
if (state == State::IDLE or dumpParams.pendingPacketDump) {
if (state == State::IDLE) {
return DUMP_DONE;
}
if (dumpParams.pendingPacketDump) {
return returnvalue::FAILED;
}
fileHasSwapped = false;