Skip to content

Fix implementation of IFindReferenceTargetsCallback::FoundTrackerTarget #115921

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

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

jkoritzinsky
Copy link
Member

@jkoritzinsky jkoritzinsky commented May 23, 2025

Fixes #115881

The implementation of FoundTrackerTarget from the ComWrappers refactoring incorrectly used the target as the source and compared syncblocks before creating the connection from source to target. As a result, the target object's live was not tied to the source object's lifetime and was released early even though it was still referenced.

@github-actions github-actions bot added the needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners label May 23, 2025
@jkoritzinsky jkoritzinsky added area-System.Runtime.InteropServices and removed needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners labels May 23, 2025
Copy link
Contributor

Tagging subscribers to this area: @dotnet/interop-contrib
See info in area-owners.md if you want to be subscribed.

…get to correctly record the found reference paths.
@jkoritzinsky jkoritzinsky force-pushed the mowholder-live-longer branch from 00f8f7c to d4fb6e5 Compare May 23, 2025 20:40
@jkoritzinsky jkoritzinsky changed the title Keep the ManageObjectWrapperHolder alive as long as the ref-counted handle to it is alive. Fix implementation of IFindReferenceTargetsCallback::FoundTrackerTarget May 23, 2025
@jkoritzinsky jkoritzinsky marked this pull request as ready for review May 23, 2025 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[dotnet-sdk-10.0.100-preview.5.25266.36] Some WinUI applications crash with exception code 0xc000027b during runtime
2 participants