Skip to content

Fix broken set_notice_(receiver|processor) callback after GC.compact - #735

Merged
larskanis merged 1 commit into
ged:masterfrom
larskanis:fix-734
Aug 11, 2026
Merged

Fix broken set_notice_(receiver|processor) callback after GC.compact#735
larskanis merged 1 commit into
ged:masterfrom
larskanis:fix-734

Conversation

@larskanis

Copy link
Copy Markdown
Collaborator

The VALUE object passed to libpq was not updated at GC.compact . Instead we better pass the xmalloc'ed TDATA pointer to libpq and add the self object to the struct as a back reference. That self object is relocated at GC.compact .

Also add a test case which triggers and verifies the relocation.

Fixes #734

The `VALUE` object passed to libpq was not updated at `GC.compact` .
Instead we better pass the xmalloc'ed TDATA pointer to libpq and add the `self` object to the struct as a back reference.
That `self` object is relocated at GC.compact .

Also add a test case which triggers and verifies the relocation.

Fixes ged#734
@larskanis
larskanis marked this pull request as ready for review August 8, 2026 13:14
@larskanis
larskanis merged commit c90097b into ged:master Aug 11, 2026
56 of 58 checks passed
@larskanis
larskanis deleted the fix-734 branch August 11, 2026 17:24
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.

set_notice_receiver/processor: raw VALUE handed to libpq breaks under GC compaction (SEGV)

1 participant