ntdll: Add support for NtSetInformationProcess(ProcessExecuteFlags).

This commit is contained in:
Dmitry Timoshkov 2008-09-04 17:37:23 +09:00 committed by Alexandre Julliard
parent 454a241e97
commit 97f2cbc1ea
2 changed files with 27 additions and 0 deletions

View File

@ -389,6 +389,28 @@ NTSTATUS WINAPI NtSetInformationProcess(
SERVER_END_REQ;
}
break;
case ProcessExecuteFlags:
if (ProcessInformationLength != sizeof(ULONG))
return STATUS_INVALID_PARAMETER;
else
{
BOOL enable;
switch (*(ULONG *)ProcessInformation & (MEM_EXECUTE_OPTION_ENABLE|MEM_EXECUTE_OPTION_DISABLE))
{
case MEM_EXECUTE_OPTION_ENABLE:
enable = FALSE;
break;
case MEM_EXECUTE_OPTION_DISABLE:
enable = TRUE;
break;
default:
return STATUS_INVALID_PARAMETER;
}
VIRTUAL_SetForceExec( enable );
}
break;
default:
FIXME("(%p,0x%08x,%p,0x%08x) stub\n",
ProcessHandle,ProcessInformationClass,ProcessInformation,

View File

@ -665,9 +665,14 @@ typedef enum _PROCESSINFOCLASS {
ProcessDebugObjectHandle = 30,
ProcessDebugFlags = 31,
ProcessHandleTracing = 32,
ProcessExecuteFlags = 34,
MaxProcessInfoClass
} PROCESSINFOCLASS, PROCESS_INFORMATION_CLASS;
#define MEM_EXECUTE_OPTION_DISABLE 0x01
#define MEM_EXECUTE_OPTION_ENABLE 0x02
#define MEM_EXECUTE_OPTION_PERMANENT 0x08
typedef enum _SECTION_INHERIT {
ViewShare = 1,
ViewUnmap = 2