Skip to content

Commit

Permalink
Merge pull request #3322 from autonomys/cross-segment-object-bug
Browse files Browse the repository at this point in the history
Fix bug in cross-segment object retrieval
  • Loading branch information
nazar-pc authored Dec 18, 2024
2 parents 3d5483e + 1e579b3 commit 778d965
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions shared/subspace-data-retrieval/src/object_fetcher.rs
Original file line number Diff line number Diff line change
Expand Up @@ -514,13 +514,12 @@ where
}
}

// Padding at the end of segments can be skipped, it's not part of the object data
SegmentItem::Padding => {}
// Padding at the end of segments, and segment headers can be skipped,
// they're not part of the object data
SegmentItem::Padding | SegmentItem::ParentSegmentHeader(_) => {}

// We should not see these items while collecting data for a single object
SegmentItem::Block { .. }
| SegmentItem::BlockStart { .. }
| SegmentItem::ParentSegmentHeader(_) => {
SegmentItem::Block { .. } | SegmentItem::BlockStart { .. } => {
debug!(
collected_data = ?data.len(),
%segment_index,
Expand Down

0 comments on commit 778d965

Please sign in to comment.