-
Notifications
You must be signed in to change notification settings - Fork 119
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Actual behavior
Below is the generated source. I believe this buffer will be left with a dangling pointer to the SourceStringLocal pointer within this wrapper.
/// <inheritdoc cref="RtlInitUnicodeString(winmdroot.Foundation.UNICODE_STRING*, winmdroot.Foundation.PCWSTR)"/>
[OverloadResolutionPriority(1)]
internal static unsafe void RtlInitUnicodeString(ref winmdroot.Foundation.UNICODE_STRING DestinationString, string SourceString)
{
fixed (char* SourceStringLocal = SourceString)
{
fixed (winmdroot.Foundation.UNICODE_STRING* DestinationStringLocal = &DestinationString)
{
PInvoke.RtlInitUnicodeString(DestinationStringLocal, SourceStringLocal);
}
}
}Expected behavior
That this friendly overload simply not exist.
Repro steps
NativeMethods.txtcontent:
RtlInitUnicodeString
-
NativeMethods.jsoncontent (if present): N/A -
Any of your own code that should be shared? N/A
Context
- CsWin32 version: 0.3.269
- Win32Metadata version: N/A
- Target Framework: net472
LangVersion: N/A
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working