Skip to content
Snippets Groups Projects
Commit 3de6ba47 authored by Vakhtang Tsulaia's avatar Vakhtang Tsulaia
Browse files

Merge branch 'main' into 'main'

bug fix with off by one pointer check

See merge request atlas/athena!69552
parents de544985 eb67be97
No related branches found
No related tags found
No related merge requests found
......@@ -107,7 +107,7 @@ void Muon::nsw::NSWTriggerSTGL1AElink::decode_data(std::size_t& readPointer) {
while (readPointer < endOfData) {
static constexpr auto SIZE_DATA_HEADER = STGTPL1A::size_stream_head_nbits + STGTPL1A::size_stream_head_nwords +
STGTPL1A::size_stream_head_fifo_size + STGTPL1A::size_stream_head_streamID;
if (readPointer + SIZE_DATA_HEADER >= endOfData) {
if (readPointer + SIZE_DATA_HEADER > endOfData) {
throw std::length_error(
Muon::nsw::format("Read pointer ({}) would excede memory dedicated to data chunks ({}) while parsing the header (size: {})",
readPointer, endOfData, SIZE_DATA_HEADER));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment