ReactOS 0.4.16-dev-1946-g52006dd
processthreadsapi.h
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS SDK
3 * LICENSE: MIT (https://spdx.org/licenses/MIT)
4 * PURPOSE: API definitions for api-ms-win-core-processthreads-l1
5 * COPYRIGHT: Copyright 2024 Timo Kreuzer (timo.kreuzer@reactos.org)
6 */
7
8#pragma once
9
10#ifdef __cplusplus
11extern "C" {
12#endif
13
14typedef struct _STARTUPINFOA
15{
35
36typedef struct _STARTUPINFOW
37{
57
58#ifdef UNICODE
60#else
62#endif // UNICODE
63
65{
71
73
79 _Outptr_result_z_ PWSTR* ppszThreadDescription);
80
86 _In_ PCWSTR lpThreadDescription);
87
89BOOL
92 _Inout_ PULONG StackSizeInBytes);
93
94#if (_WIN32_WINNT >= 0x0600)
95
97VOID
99FlushProcessWriteBuffers(
100 VOID);
101
103_Success_(return != FALSE)
104BOOL
105WINAPI
107 _Out_writes_bytes_to_opt_(*lpSize,*lpSize) LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList,
108 _In_ DWORD dwAttributeCount,
110 _When_(lpAttributeList == nullptr,_Out_) _When_(lpAttributeList != nullptr,_Inout_) PSIZE_T lpSize);
111
113BOOL
114WINAPI
118 _In_ DWORD_PTR Attribute,
119 _In_reads_bytes_opt_(cbSize) PVOID lpValue,
120 _In_ SIZE_T cbSize,
121 _Out_writes_bytes_opt_(cbSize) PVOID lpPreviousValue,
122 _In_opt_ PSIZE_T lpReturnSize);
123
125VOID
126WINAPI
128 _Inout_ LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList);
129
130#endif // (_WIN32_WINNT >= 0x0600) || defined(__REACTOS__)
131
132#if (_WIN32_WINNT >= 0x602) || defined(__REACTOS__)
133
135HANDLE
137 VOID)
138{
139 return (HANDLE)(LONG_PTR)-4;
140}
141
143HANDLE
145 VOID)
146{
147 return (HANDLE)(LONG_PTR)-5;
148}
149
151HANDLE
153 VOID)
154{
155 return (HANDLE)(LONG_PTR)-6;
156}
157
158#endif // (_WIN32_WINNT >= 0x602) || defined(__REACTOS__)
159
161{
167 ProcessReservedValue1, // Formerly ProcessActivityThrottlePolicyInfo
176
177#ifdef __cplusplus
178} // extern "C"
179#endif
#define FALSE
Definition: types.h:117
void WINAPI DECLSPEC_HOTPATCH DeleteProcThreadAttributeList(struct _PROC_THREAD_ATTRIBUTE_LIST *list)
Definition: process.c:1860
BOOL WINAPI DECLSPEC_HOTPATCH UpdateProcThreadAttribute(struct _PROC_THREAD_ATTRIBUTE_LIST *list, DWORD flags, DWORD_PTR attr, void *value, SIZE_T size, void *prev_ret, SIZE_T *size_ret)
Definition: process.c:1820
BOOL WINAPI DECLSPEC_HOTPATCH InitializeProcThreadAttributeList(struct _PROC_THREAD_ATTRIBUTE_LIST *list, DWORD count, DWORD flags, SIZE_T *size)
Definition: process.c:1753
unsigned short WORD
Definition: ntddk_ex.h:93
unsigned int BOOL
Definition: ntddk_ex.h:94
unsigned long DWORD
Definition: ntddk_ex.h:95
#define WINBASEAPI
Definition: green.h:8
#define GetCurrentProcessToken()
Definition: security.c:40
#define GetCurrentThreadEffectiveToken()
Definition: security.c:42
#define GetCurrentThreadToken()
Definition: security.c:41
#define _Outptr_result_z_
Definition: ms_sal.h:434
_In_ LPWSTR _In_ DWORD _In_ DWORD _In_ DWORD dwFlags
Definition: netsh.h:141
HANDLE hThread
Definition: wizard.c:28
#define _Inout_
Definition: no_sal2.h:162
#define _Success_(c)
Definition: no_sal2.h:84
#define _Out_writes_bytes_opt_(s)
Definition: no_sal2.h:228
#define _Out_
Definition: no_sal2.h:160
#define _In_
Definition: no_sal2.h:158
#define _In_opt_
Definition: no_sal2.h:212
#define _Out_writes_bytes_to_opt_(s, c)
Definition: no_sal2.h:240
#define _Reserved_
Definition: no_sal2.h:504
#define _When_(c, a)
Definition: no_sal2.h:38
#define _In_reads_bytes_opt_(s)
Definition: no_sal2.h:224
BYTE * PBYTE
Definition: pedump.c:66
struct _PROC_THREAD_ATTRIBUTE_LIST * PPROC_THREAD_ATTRIBUTE_LIST
_PROCESS_INFORMATION_CLASS
@ ProcessOverrideSubsequentPrefetchParameter
@ ProcessMachineTypeInfo
@ ProcessTelemetryCoverageInfo
@ ProcessInPrivateInfo
@ ProcessProtectionLevelInfo
@ ProcessLeapSecondInfo
@ ProcessMemoryPriority
@ ProcessMemoryExhaustionInfo
@ ProcessInformationClassMax
@ ProcessPowerThrottling
@ ProcessAppMemoryInfo
@ ProcessReservedValue1
@ ProcessMaxOverridePrefetchParameter
struct _PROCESS_INFORMATION * PPROCESS_INFORMATION
struct _STARTUPINFOA STARTUPINFOA
WINBASEAPI HRESULT WINAPI SetThreadDescription(_In_ HANDLE hThread, _In_ PCWSTR lpThreadDescription)
struct _PROCESS_INFORMATION PROCESS_INFORMATION
enum _PROCESS_INFORMATION_CLASS PROCESS_INFORMATION_CLASS
STARTUPINFOA STARTUPINFO
WINBASEAPI BOOL WINAPI SetThreadStackGuarantee(_Inout_ PULONG StackSizeInBytes)
struct _STARTUPINFOW * LPSTARTUPINFOW
STARTUPINFOA * LPSTARTUPINFO
struct _PROC_THREAD_ATTRIBUTE_LIST * LPPROC_THREAD_ATTRIBUTE_LIST
WINBASEAPI HRESULT WINAPI GetThreadDescription(_In_ HANDLE hThread, _Outptr_result_z_ PWSTR *ppszThreadDescription)
struct _PROCESS_INFORMATION * LPPROCESS_INFORMATION
struct _STARTUPINFOW STARTUPINFOW
struct _STARTUPINFOA * LPSTARTUPINFOA
#define LONG_PTR
Definition: treelist.c:79
ULONG_PTR * PSIZE_T
Definition: typedefs.h:80
uint16_t * PWSTR
Definition: typedefs.h:56
uint32_t * PULONG
Definition: typedefs.h:59
const uint16_t * PCWSTR
Definition: typedefs.h:57
uint32_t DWORD_PTR
Definition: typedefs.h:65
ULONG_PTR SIZE_T
Definition: typedefs.h:80
#define FORCEINLINE
Definition: wdftypes.h:67
#define WINAPI
Definition: msvc.h:6
WCHAR * LPWSTR
Definition: xmlstorage.h:184
char * LPSTR
Definition: xmlstorage.h:182