We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f632627 commit 4af33fbCopy full SHA for 4af33fb
1 file changed
Svc/Ccsds/SpacePacketDeframer/SpacePacketDeframer.cpp
@@ -65,7 +65,8 @@ void SpacePacketDeframer ::dataIn_handler(FwIndexType portNum, Fw::Buffer& data,
65
// Widen to U32 before adding 1 to prevent U16 truncation to 0 when packetDataLength == 0xFFFF (max U16 value).
66
// This is a undefined behavior condition in C++.
67
const U32 pkt_length = static_cast<U32>(header.get_packetDataLength()) + 1U;
68
- if ((pkt_length > data.getSize() - SpacePacketHeader::SERIALIZED_SIZE) || (pkt_length > std::numeric_limits<FwSizeType>::max())) {
+ if ((pkt_length > data.getSize() - SpacePacketHeader::SERIALIZED_SIZE) ||
69
+ (pkt_length > std::numeric_limits<FwSizeType>::max())) {
70
FwSizeType maxDataAvailable = data.getSize() - SpacePacketHeader::SERIALIZED_SIZE;
71
this->log_WARNING_HI_InvalidLength(pkt_length, maxDataAvailable);
72
if (this->isConnected_errorNotify_OutputPort(0)) {
0 commit comments