reactos/sdk
Bișoc George 7481bda679
[SDK][NDK][PSTYPES] Align the PROCESS_PRIORITY_CLASS structure during compile time (#2478)
CORE-16757

After doing investigations on the priority class structure alignment, it's been revealed that in Windows XP and Server 2003 this PROCESS_PRIORITY_CLASS structure is aligned as a 4-bytes of size hence NtQueryInformationProcess() probes the alignment of user mode arguments buffer output and buffer length with requirement of a ULONG.

As PROCESS_PRIORITY_CLASS was initially aligned as a 1-byte size because both BOOLEAN and UCHAR are just unsigned characters, the compiler may not align such structure and gracefully let the default alignment of such structure as is, 1-byte because an unsigned char has a size of 1 byte. Setting an align attribute to this structure fixes the problem of a potential datatype misalignment which caused GetPriorityClass() to not retrieve the process' priority class properly.
2020-03-28 19:17:10 +01:00
..
cmake [PRINTING] Add x64 print environment keys and folders 2020-03-09 07:03:47 +01:00
include [SDK][NDK][PSTYPES] Align the PROCESS_PRIORITY_CLASS structure during compile time (#2478) 2020-03-28 19:17:10 +01:00
lib [TCPIP] Add some static specifiers, to prevent exporting FORCEINLINE function outside compilation unit 2020-03-26 16:39:16 +01:00
tools [WINESYNC]: d3dx9 is now in sync with wine-staging wine-4.2 2020-02-26 18:19:18 +01:00