16#ifdef INCLUDE_CMD_START
29 bInQuote ^= (*
p ==
_T(
'"'));
56 DWORD dwAffinityMask = 0;
73 else if (*Rest ==
_T(
'/'))
115 if (*
end !=
_T(
'\0') || dwAffinityMask == 0 ||
116 dwAffinityMask == (
DWORD)-1)
125 dwCreationFlags &= ~CREATE_NEW_CONSOLE;
183 WARN(
"Cannot allocate memory for start comspec!\n");
197 LPTSTR Oldcomspec = comspec;
212 Rest =
_T(
"cmd.exe");
220 for (
i = 0; Rest[
i];
i++)
222 if (Rest[
i] ==
_T(
'\"'))
245 _stprintf(szFullCmdLine,
_T(
"\"%s\" /K %s"), comspec, Rest);
251 _tcscpy(szFullCmdLine, szFullName);
285 _tcscpy(szFullName, szUnquotedName);
336 _T(
"Error executing CreateProcess()!!\n"));
static VOID ErrorMessage(_In_ DWORD dwErrorCode, _In_opt_ PCWSTR pszMsg,...)
#define STRING_ERROR_INVALID_PARAM_FORMAT
LPTSTR lpOriginalEnvironment
HANDLE RunFile(DWORD flags, LPTSTR filename, LPTSTR params, LPTSTR directory, INT show)
BOOL SearchForExecutable(LPCTSTR, LPTSTR)
VOID error_out_of_memory(VOID)
VOID ConOutResPaging(BOOL StartPaging, UINT resID)
#define ConErrResPrintf(uID,...)
#define STRING_TYPE_ERROR
#define STRING_START_HELP1
static VOID StripQuotes(LPSTR in)
#define cmd_realloc(ptr, size)
UINT WINAPI DECLSPEC_HOTPATCH GetConsoleOutputCP(VOID)
UINT WINAPI DECLSPEC_HOTPATCH GetConsoleCP(VOID)
BOOL WINAPI GetExitCodeProcess(IN HANDLE hProcess, IN LPDWORD lpExitCode)
BOOL WINAPI SetProcessAffinityMask(IN HANDLE hProcess, IN DWORD_PTR dwProcessAffinityMask)
DWORD WINAPI ResumeThread(IN HANDLE hThread)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define IsConsoleHandle(h)
HANDLE ConStreamGetOSHandle(IN PCON_STREAM Stream)
#define ConStdStreamsSetCacheCodePage(InputCodePage, OutputCodePage)
LANGID ConSetThreadUILanguage(IN LANGID LangId OPTIONAL)
static TCHAR * GetParameter(TCHAR **pPointer)
INT cmd_start(LPTSTR Rest)
#define SEE_MASK_NOCLOSEPROCESS
_In_opt_ LPCSTR lpDirectory
#define SEE_MASK_NO_CONSOLE
_In_ int _In_ BOOL bCreate
DWORD WINAPI WaitForSingleObject(IN HANDLE hHandle, IN DWORD dwMilliseconds)
#define GetEnvironmentVariable
#define NORMAL_PRIORITY_CLASS
DWORD WINAPI GetLastError(void)
#define STARTF_USESHOWWINDOW
#define REALTIME_PRIORITY_CLASS
#define BELOW_NORMAL_PRIORITY_CLASS
#define CREATE_UNICODE_ENVIRONMENT
#define HIGH_PRIORITY_CLASS
#define CREATE_SHARED_WOW_VDM
#define CREATE_SEPARATE_WOW_VDM
#define CREATE_NEW_PROCESS_GROUP
#define IDLE_PRIORITY_CLASS
#define CREATE_NEW_CONSOLE
#define ABOVE_NORMAL_PRIORITY_CLASS
#define ERROR_ENVVAR_NOT_FOUND