fix PTME
All checks were successful
EIVE/eive-obsw/pipeline/head This commit looks good

This commit is contained in:
2023-10-13 09:20:51 +02:00
parent 433373e6b7
commit ffe1281eb9
20 changed files with 141 additions and 94 deletions

View File

@ -36,8 +36,19 @@ ReturnValue_t VirtualChannelWithQueue::handleNextTm(bool performWriteOp) {
return result;
}
// TODO: Hnadle partial write handling
size_t partiallyWrittenSize = 0;
if (performWriteOp) {
result = write(data, size);
result = write(data, size, partiallyWrittenSize);
if (result == PARTIALLY_WRITTEN) {
result = handleLastWriteSynchronously(data, size, partiallyWrittenSize, 20);
if (result != returnvalue::OK) {
// TODO: Event? Might lead to dangerous spam though..
sif::warning
<< "VirtualChannelWithQueue: Synchronous write of last segment failed with code 0x"
<< std::setw(4) << std::hex << result << std::endl;
}
}
}
// Try delete in any case, ignore failures (which should not happen), it is more important to
// propagate write errors.