Skip to content

Commit

Permalink
fix: correct the range check for descriptor IDs
Browse files Browse the repository at this point in the history
  • Loading branch information
tri-adam committed Aug 23, 2024
1 parent fd8a090 commit 390d447
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/sif/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ func (f *FileImage) writeDataObject(i int, di DescriptorInput, t time.Time) erro
}

// We derive the ID from i, so make sure the ID will not overflow.
if i >= math.MaxInt32 {
if i >= math.MaxUint32 {
return errObjectIDOverflow
}

Expand Down

0 comments on commit 390d447

Please sign in to comment.