Skip to content

Conversation

shantanuraj
Copy link
Contributor

@shantanuraj shantanuraj commented Sep 8, 2025

We create a new instance of newStruct instead of reusing the previous oneStruct
Ensures memory is not shared between slice elements.

The tests from #1426 pass on this branch

go test github.com/aarondl/sqlboiler/v4/queries -run "TestBindJsonSlice"

Closes #1427

@stephenafamo stephenafamo merged commit 544e18d into aarondl:master Sep 9, 2025
2 checks passed
@shantanuraj shantanuraj deleted the shantanu/fix-json-buffer-reuse branch September 9, 2025 08:02
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.

Buffer reuse/overwrite bug when reading results into types.JSON values

3 participants