Skip to content

Defensively copy bytes values#901

Merged
snazy merged 1 commit into
projectnessie:mainfrom
snazy:def-bytes-copy
Jul 17, 2026
Merged

Defensively copy bytes values#901
snazy merged 1 commit into
projectnessie:mainfrom
snazy:def-bytes-copy

Conversation

@snazy

@snazy snazy commented Jul 16, 2026

Copy link
Copy Markdown
Member

BytesT exposed mutable byte arrays through construction and native conversion paths, allowing external mutation to change equality and hash-code behavior.

Copy caller-provided and returned arrays, return a read-only ByteBuffer over a copy, and cover the mutation paths in unit tests.

BytesT exposed mutable byte arrays through construction and native conversion paths, allowing external mutation to change equality and hash-code behavior.

Copy caller-provided and returned arrays, return a read-only ByteBuffer over a copy, and cover the mutation paths in unit tests.
@snazy
snazy requested a review from XN137 July 16, 2026 15:54
@snazy
snazy merged commit 58f6799 into projectnessie:main Jul 17, 2026
3 checks passed
@snazy
snazy deleted the def-bytes-copy branch July 17, 2026 06:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants