From 765c587245d3bc453ea7cc9ead4ed71f3395588b Mon Sep 17 00:00:00 2001 From: Andrew Arnott Date: Tue, 29 Dec 2015 10:37:26 -0800 Subject: [PATCH] Finish removal of IntPtr method overloads in Kernel32 --- src/Kernel32.Desktop/Kernel32.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Kernel32.Desktop/Kernel32.cs b/src/Kernel32.Desktop/Kernel32.cs index 86c53ea4..b76db0dd 100644 --- a/src/Kernel32.Desktop/Kernel32.cs +++ b/src/Kernel32.Desktop/Kernel32.cs @@ -227,8 +227,8 @@ public static extern void GetStartupInfo( /// /// /// First, call this function with the parameter set to the maximum number of attributes you will be using and the lpAttributeList to NULL. The function returns the required buffer size in bytes in the lpSize parameter. Allocate enough space for the data in the lpAttributeList buffer and call the function again to initialize the buffer. - /// To add attributes to the list, call the function. To specify these attributes when creating a process, specify in the dwCreationFlag parameter and a structure in the lpStartupInfo parameter. Note that you can specify the same structure to multiple child processes. - /// When you have finished using the list, call the function. + /// To add attributes to the list, call the function. To specify these attributes when creating a process, specify in the dwCreationFlag parameter and a structure in the lpStartupInfo parameter. Note that you can specify the same structure to multiple child processes. + /// When you have finished using the list, call the function. /// [DllImport(api_ms_win_core_processthreads_l1_1_1, SetLastError = true)] [return: MarshalAs(UnmanagedType.Bool)] @@ -251,7 +251,7 @@ public static unsafe extern bool InitializeProcThreadAttributeList( /// The attribute key to update in the attribute list. /// /// - /// A pointer to the attribute value. This value should persist until the attribute is destroyed using the function. + /// A pointer to the attribute value. This value should persist until the attribute is destroyed using the function. /// /// /// The size of the attribute value specified by the parameter. @@ -270,7 +270,7 @@ public static unsafe extern bool UpdateProcThreadAttribute( PROC_THREAD_ATTRIBUTE_LIST* lpAttributeList, uint dwFlags, ref uint Attribute, - IntPtr lpValue, + void* lpValue, IntPtr cbSize, // SIZE_T varies by bitness ref IntPtr lpPreviousValue, ref IntPtr lpReturnSize); @@ -282,8 +282,8 @@ public static unsafe extern bool UpdateProcThreadAttribute( /// The attribute list. This list is created by the function. /// [DllImport(api_ms_win_core_processthreads_l1_1_1)] - public static extern void DeleteProcThreadAttributeList( - IntPtr lpAttributeList); + public static unsafe extern void DeleteProcThreadAttributeList( + PROC_THREAD_ATTRIBUTE_LIST* lpAttributeList); /// /// Allocates a new console for the calling process.