-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Only call Free in unmanaged->managed stubs when ownership has been transfered to the callee #86415
Conversation
Tagging subscribers to this area: @dotnet/interop-contrib Issue DetailsFixes #85795
|
d43ce76
to
18b5e4a
Compare
...Microsoft.Interop.SourceGeneration/Marshalling/AttributedMarshallingModelGeneratorFactory.cs
Outdated
Show resolved
Hide resolved
...nteropServices/tests/ComInterfaceGenerator.Tests/UnmanagedToManagedCustomMarshallingTests.cs
Show resolved
Hide resolved
...pServices/gen/Microsoft.Interop.SourceGeneration/Marshalling/StatelessMarshallingStrategy.cs
Outdated
Show resolved
Hide resolved
18b5e4a
to
fafc39a
Compare
…ansfered to the callee Fixes dotnet#85795
…sable by-value [In,Out] on unmanged->managed for now as it's difficult to reason about.
…o-managed. It still needs additional work to function, but this at least fixes the compilation problems, enabling usage in managed->unmanaged COM scenarios.
fafc39a
to
fcefc57
Compare
… the expectation (always free stateful marshaller state, only free elements when we're supposed to).
I've updated this PR to correctly handle lifetimes for collection marshallers (stateless and stateful). I've opened #86608 to track additional work to complete this story. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
All failures are known |
Fixes #85795