From c5248931b112e3f2dc40e7c86ee82a154b5d71ab Mon Sep 17 00:00:00 2001 From: Amine Khaldi Date: Thu, 16 Aug 2012 15:39:40 +0000 Subject: [PATCH] [KERNEL32] * Fix a comment and a last error value. By Hermes Belusca. See issue #7240 for more details. svn path=/trunk/; revision=57086 --- reactos/dll/win32/kernel32/client/proc.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/reactos/dll/win32/kernel32/client/proc.c b/reactos/dll/win32/kernel32/client/proc.c index 3975f8169a3..ab8d6ee37c7 100644 --- a/reactos/dll/win32/kernel32/client/proc.c +++ b/reactos/dll/win32/kernel32/client/proc.c @@ -2976,7 +2976,11 @@ GetAppName: IMAGE_SUBSYSTEM_WINDOWS_CUI != SectionImageInfo.SubSystemType) { DPRINT1("Invalid subsystem %d\n", SectionImageInfo.SubSystemType); - SetLastError(ERROR_BAD_EXE_FORMAT); + /* + * Despite the name of the error code suggests, it corresponds to the + * well-known "The %1 application cannot be run in Win32 mode" message. + */ + SetLastError(ERROR_CHILD_NOT_COMPLETE); goto Cleanup; } @@ -3269,7 +3273,7 @@ Cleanup: if (hSection) NtClose(hSection); if (hThread) { - /* We don't know any more details then this */ + /* We don't know any more details than this */ NtTerminateProcess(hProcess, STATUS_UNSUCCESSFUL); NtClose(hThread); }