Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wayland.pointer_constraints: Remove constraints in the destructor #1568

Merged
merged 1 commit into from
Oct 25, 2024

Conversation

PolyMeilex
Copy link
Member

I'm pretty sure this works fine as is, but just to be 100% sure that the reference cycle (see #1552) gets broken properly, let's remove the constraint in the destructor rather than on event.

remove_constraint removes the constraint object from wlsurface user data, and as the constraint object contains the surface in its own user data this makes sure that the cycle is broken properly.

@Drakulix
Copy link
Member

CI doesn't seem to be happy

@PolyMeilex PolyMeilex merged commit 6ccbe9d into Smithay:master Oct 25, 2024
13 checks passed
@PolyMeilex PolyMeilex deleted the constraints-destructor branch October 25, 2024 21:20
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