#include "precomp.h"
Go to the source code of this file.
Defines | |
#define | CONSOLE_NAME_PATH_SEPARATOR ((WCHAR)L'\\') |
#define | CONSOLE_NAME_PATH_TERMINATOR ((WCHAR)L'\0') |
#define | FNAME_LENGTH 256 |
Functions | |
VOID | InitExeName (VOID) |
USHORT | GetCurrentExeName (OUT LPWSTR Buffer, IN ULONG BufferLength) |
USHORT | GetExeName (IN OUT LPVOID *ExeName, IN BOOLEAN UnicodeApi, OUT PBOOLEAN UnicodeExe) |
defined(BUILD_WOW64) | |
BOOL APIENTRY | AddConsoleAliasInternal (IN LPVOID Source, IN UINT SourceLength, IN LPVOID Target, IN UINT TargetLength, IN LPVOID ExeName, IN BOOLEAN Unicode) |
BOOL APIENTRY | AddConsoleAliasW (IN LPWSTR Source, IN LPWSTR Target, IN LPWSTR ExeName) |
defined(BUILD_WOW6432) | |
BOOL APIENTRY | AddConsoleAliasA (IN LPTSTR Source, IN LPTSTR Target, IN LPTSTR ExeName) |
DWORD APIENTRY | GetConsoleAliasInternal (IN LPVOID Source, IN UINT SourceLength, OUT LPVOID TargetBuffer, IN UINT TargetBufferLength, IN LPVOID ExeName, IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
DWORD APIENTRY | GetConsoleAliasW (IN LPWSTR Source, OUT LPWSTR TargetBuffer, IN DWORD TargetBufferLength, IN LPWSTR ExeName) |
DWORD APIENTRY | GetConsoleAliasA (IN LPTSTR Source, OUT LPTSTR TargetBuffer, IN DWORD TargetBufferLength, IN LPTSTR ExeName) |
DWORD APIENTRY | GetConsoleAliasesLengthInternal (IN LPVOID ExeName, IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
DWORD APIENTRY | GetConsoleAliasesLengthW (IN LPWSTR ExeName) |
defined(BUILD_WOW6432) | |
DWORD APIENTRY | GetConsoleAliasesLengthA (IN LPTSTR ExeName) |
DWORD APIENTRY | GetConsoleAliasExesLengthInternal (IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
DWORD APIENTRY | GetConsoleAliasExesLengthW (VOID) |
defined(BUILD_WOW6432) | |
DWORD APIENTRY | GetConsoleAliasExesLengthA (VOID) |
DWORD APIENTRY | GetConsoleAliasesInternal (OUT LPVOID AliasBuffer, IN DWORD AliasBufferLength, IN LPVOID ExeName, IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
DWORD | GetConsoleAliasesW (OUT LPWSTR AliasBuffer, IN DWORD AliasBufferLength, IN LPWSTR ExeName) |
defined(BUILD_WOW6432) | |
DWORD | GetConsoleAliasesA (OUT LPTSTR AliasBuffer, IN DWORD AliasBufferLength, IN LPTSTR ExeName) |
DWORD APIENTRY | GetConsoleAliasExesInternal (OUT LPVOID ExeNameBuffer, IN DWORD ExeNameBufferLength, IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
DWORD | GetConsoleAliasExesW (OUT LPWSTR ExeNameBuffer, IN DWORD ExeNameBufferLength) |
defined(BUILD_WOW6432) | |
DWORD | GetConsoleAliasExesA (OUT LPTSTR ExeNameBuffer, IN DWORD ExeNameBufferLength) |
VOID APIENTRY | ExpungeConsoleCommandHistoryInternal (IN LPVOID ExeName, IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
VOID | ExpungeConsoleCommandHistoryW (IN LPWSTR ExeName) |
defined(BUILD_WOW6432) | |
VOID | ExpungeConsoleCommandHistoryA (IN LPTSTR ExeName) |
BOOL APIENTRY | SetConsoleNumberOfCommandsInternal (IN DWORD Number, IN LPVOID ExeName, IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
BOOL | SetConsoleNumberOfCommandsW (IN DWORD Number, IN LPWSTR ExeName) |
defined(BUILD_WOW6432) | |
BOOL | SetConsoleNumberOfCommandsA (IN DWORD Number, IN LPTSTR ExeName) |
DWORD APIENTRY | GetConsoleCommandHistoryLengthInternal (IN LPVOID ExeName, IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
DWORD | GetConsoleCommandHistoryLengthW (IN LPWSTR ExeName) |
defined(BUILD_WOW6432) | |
DWORD | GetConsoleCommandHistoryLengthA (IN LPTSTR ExeName) |
DWORD APIENTRY | GetConsoleCommandHistoryInternal (OUT LPVOID Commands, IN DWORD CommandBufferLength, IN LPVOID ExeName, IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
DWORD | GetConsoleCommandHistoryW (OUT LPWSTR Commands, IN DWORD CommandBufferLength, IN LPWSTR ExeName) |
defined(BUILD_WOW6432) | |
DWORD | GetConsoleCommandHistoryA (OUT LPTSTR Commands, IN DWORD CommandBufferLength, IN LPTSTR ExeName) |
BOOL APIENTRY | SetConsoleCommandHistoryMode (IN DWORD Flags) |
defined(BUILD_WOW64) | |
DWORD APIENTRY | GetConsoleTitleInternal (OUT PVOID lpConsoleTitle, IN DWORD nSize, IN BOOLEAN Unicode) |
DWORD APIENTRY | GetConsoleTitleA (LPSTR lpConsoleTitle, DWORD nSize) |
defined(BUILD_WOW6432) | |
DWORD APIENTRY | GetConsoleTitleW (LPWSTR lpConsoleTitle, DWORD nSize) |
BOOL APIENTRY | SetConsoleTitleInternal (IN CONST VOID *lpConsoleTitle, IN DWORD TitleLength, IN BOOLEAN Unicode) |
defined(BUILD_WOW64) | |
BOOL APIENTRY | SetConsoleTitleA (LPCSTR lpConsoleTitle) |
defined(BUILD_WOW6432) | |
BOOL APIENTRY | SetConsoleTitleW (LPCWSTR lpConsoleTitle) |
DWORD | GetConsoleInputExeNameA (IN DWORD nBufferLength, OUT LPSTR lpBuffer) |
DWORD | GetConsoleInputExeNameW (IN DWORD nBufferLength, OUT LPWSTR lpBuffer) |
BOOL | SetConsoleInputExeNameA (IN LPSTR lpExeName) |
BOOL | SetConsoleInputExeNameW (IN LPWSTR lpExeName) |
Variables | |
BOOLEAN | ExeNameInitialized |
RTL_CRITICAL_SECTION | ExeNameCriticalSection |
WCHAR | ExeNameBuffer [FNAME_LENGTH] |
USHORT | ExeNameLength |
WCHAR | StartDirBuffer [MAX_PATH+1] |
USHORT | StartDirLength |
|
Definition at line 25 of file client/cmdline.c. |
|
Definition at line 26 of file client/cmdline.c. Referenced by GetConsoleTitleW(), and InitExeName(). |
|
Definition at line 30 of file client/cmdline.c. Referenced by GetConsoleInputExeNameA(), and SetConsoleInputExeNameW(). |
|
Definition at line 252 of file client/cmdline.c. References AddConsoleAliasInternal(), FALSE, NULL, and USHORT.
|
|
Definition at line 126 of file client/cmdline.c. References CONSOLE_API_MSG, _CONSOLE_ADDALIAS_MSG::ConsoleHandle, ConsolepAddAlias, CsrAllocateCaptureBuffer(), CsrCaptureMessageBuffer(), CsrClientCallServer(), CsrFreeCaptureBuffer(), _CONSOLE_ADDALIAS_MSG::Exe, _CONSOLE_ADDALIAS_MSG::ExeLength, FALSE, GET_CONSOLE_HANDLE, GetExeName(), NT_SUCCESS, NULL, PCONSOLE_ADDALIAS_MSG, SET_LAST_ERROR, SET_LAST_NT_ERROR, _CONSOLE_ADDALIAS_MSG::Source, _CONSOLE_ADDALIAS_MSG::SourceLength, _CONSOLE_ADDALIAS_MSG::Target, _CONSOLE_ADDALIAS_MSG::TargetLength, TRUE, _CONSOLE_API_MSG::u, _CONSOLE_ADDALIAS_MSG::Unicode, Unicode, _CONSOLE_ADDALIAS_MSG::UnicodeExe, and USHORT. Referenced by AddConsoleAliasA(), and AddConsoleAliasW().
|
|
defined(BUILD_WOW6432)
Definition at line 228 of file client/cmdline.c. References AddConsoleAliasInternal(), NULL, TRUE, and USHORT.
|
|
Definition at line 785 of file client/cmdline.c. References ExpungeConsoleCommandHistoryInternal(), and FALSE.
|
|
|
defined(BUILD_WOW6432)
Definition at line 777 of file client/cmdline.c. References ExpungeConsoleCommandHistoryInternal(), and TRUE.
|
|
Definition at line 403 of file client/cmdline.c. References FALSE, and GetConsoleAliasInternal().
|
|
Definition at line 628 of file client/cmdline.c. References FALSE, and GetConsoleAliasesInternal().
|
|
defined(BUILD_WOW64)
Definition at line 550 of file client/cmdline.c. References _CONSOLE_GETALIASES_MSG::AliasesBuffer, _CONSOLE_GETALIASES_MSG::AliasesBufferLength, _CONSOLE_GETALIASES_MSG::ConsoleHandle, ConsolepGetAliases, CsrAllocateCaptureBuffer(), CsrCaptureMessageBuffer(), CsrClientCallServer(), CsrFreeCaptureBuffer(), EXCEPTION_EXECUTE_HANDLER, _CONSOLE_GETALIASES_MSG::Exe, _CONSOLE_GETALIASES_MSG::ExeLength, FALSE, GET_CONSOLE_HANDLE, GetExeName(), NT_SUCCESS, NULL, PCONSOLE_GETALIASES_MSG, SET_LAST_ERROR, SET_LAST_NT_ERROR, _CONSOLE_API_MSG::u, Unicode, _CONSOLE_GETALIASES_MSG::Unicode, and _CONSOLE_GETALIASES_MSG::UnicodeExe. Referenced by GetConsoleAliasesA(), and GetConsoleAliasesW().
|
|
Definition at line 485 of file client/cmdline.c. References FALSE, and GetConsoleAliasesLengthInternal().
|
|
defined(BUILD_WOW64)
Definition at line 425 of file client/cmdline.c. References _CONSOLE_GETALIASESLENGTH_MSG::ConsoleHandle, ConsolepGetAliasesLength, CsrAllocateCaptureBuffer(), CsrCaptureMessageBuffer(), CsrClientCallServer(), CsrFreeCaptureBuffer(), _CONSOLE_GETALIASESLENGTH_MSG::Exe, _CONSOLE_GETALIASESLENGTH_MSG::ExeLength, FALSE, GET_CONSOLE_HANDLE, GetExeName(), NT_SUCCESS, NULL, PCONSOLE_GETALIASESLENGTH_MSG, SET_LAST_ERROR, SET_LAST_NT_ERROR, _CONSOLE_API_MSG::u, Unicode, _CONSOLE_GETALIASESLENGTH_MSG::Unicode, and _CONSOLE_GETALIASESLENGTH_MSG::UnicodeExe. Referenced by GetConsoleAliasesLengthA(), and GetConsoleAliasesLengthW().
|
|
defined(BUILD_WOW6432)
Definition at line 474 of file client/cmdline.c. References GetConsoleAliasesLengthInternal(), and TRUE.
|
|
defined(BUILD_WOW6432)
Definition at line 614 of file client/cmdline.c. References GetConsoleAliasesInternal(), and TRUE.
|
|
Definition at line 716 of file client/cmdline.c. References ExeNameBuffer, FALSE, and GetConsoleAliasExesInternal().
|
|
defined(BUILD_WOW64)
Definition at line 647 of file client/cmdline.c. References _CONSOLE_GETALIASEXES_MSG::AliasExesBuffer, _CONSOLE_GETALIASEXES_MSG::AliasExesBufferLength, _CONSOLE_GETALIASEXES_MSG::ConsoleHandle, ConsolepGetAliasExes, CsrAllocateCaptureBuffer(), CsrCaptureMessageBuffer(), CsrClientCallServer(), CsrFreeCaptureBuffer(), EXCEPTION_EXECUTE_HANDLER, ExeNameBuffer, FALSE, GET_CONSOLE_HANDLE, NT_SUCCESS, NULL, PCONSOLE_GETALIASEXES_MSG, SET_LAST_ERROR, SET_LAST_NT_ERROR, _CONSOLE_API_MSG::u, _CONSOLE_GETALIASEXES_MSG::Unicode, and Unicode. Referenced by GetConsoleAliasExesA(), and GetConsoleAliasExesW().
|
|
Definition at line 539 of file client/cmdline.c. References FALSE, and GetConsoleAliasExesLengthInternal().
|
|
defined(BUILD_WOW64)
Definition at line 500 of file client/cmdline.c. References _CONSOLE_GETALIASEXESLENGTH_MSG::ConsoleHandle, ConsolepGetAliasExesLength, CsrClientCallServer(), GET_CONSOLE_HANDLE, NT_SUCCESS, NULL, PCONSOLE_GETALIASEXESLENGTH_MSG, SET_LAST_NT_ERROR, _CONSOLE_API_MSG::u, _CONSOLE_GETALIASEXESLENGTH_MSG::Unicode, and Unicode. Referenced by GetConsoleAliasExesLengthA(), and GetConsoleAliasExesLengthW().
|
|
defined(BUILD_WOW6432)
Definition at line 532 of file client/cmdline.c. References GetConsoleAliasExesLengthInternal(), and TRUE.
|
|
defined(BUILD_WOW6432)
Definition at line 704 of file client/cmdline.c. References ExeNameBuffer, GetConsoleAliasExesInternal(), and TRUE.
|
|
defined(BUILD_WOW64)
Definition at line 280 of file client/cmdline.c. References _CONSOLE_GETALIAS_MSG::ConsoleHandle, ConsolepGetAlias, CsrAllocateCaptureBuffer(), CsrCaptureMessageBuffer(), CsrClientCallServer(), CsrFreeCaptureBuffer(), _CONSOLE_GETALIAS_MSG::Exe, _CONSOLE_GETALIAS_MSG::ExeLength, FALSE, GET_CONSOLE_HANDLE, GetExeName(), NT_SUCCESS, NULL, PCONSOLE_GETALIAS_MSG, SET_LAST_ERROR, SET_LAST_NT_ERROR, _CONSOLE_GETALIAS_MSG::Source, _CONSOLE_GETALIAS_MSG::SourceLength, _CONSOLE_GETALIAS_MSG::Target, _CONSOLE_GETALIAS_MSG::TargetLength, _CONSOLE_API_MSG::u, _CONSOLE_GETALIAS_MSG::Unicode, Unicode, _CONSOLE_GETALIAS_MSG::UnicodeExe, and USHORT. Referenced by GetConsoleAliasA(), and GetConsoleAliasW().
|
|
Definition at line 385 of file client/cmdline.c. References GetConsoleAliasInternal(), and TRUE.
|
|
Definition at line 1024 of file client/cmdline.c. References Commands, FALSE, and GetConsoleCommandHistoryInternal().
|
|
defined(BUILD_WOW64)
Definition at line 945 of file client/cmdline.c. References _CONSOLE_GETCOMMANDHISTORY_MSG::CommandBuffer, _CONSOLE_GETCOMMANDHISTORY_MSG::CommandBufferLength, Commands, _CONSOLE_GETCOMMANDHISTORY_MSG::ConsoleHandle, ConsolepGetCommandHistory, CsrAllocateCaptureBuffer(), CsrCaptureMessageBuffer(), CsrClientCallServer(), CsrFreeCaptureBuffer(), EXCEPTION_EXECUTE_HANDLER, _CONSOLE_GETCOMMANDHISTORY_MSG::Exe, _CONSOLE_GETCOMMANDHISTORY_MSG::ExeLength, GET_CONSOLE_HANDLE, GetExeName(), NT_SUCCESS, NULL, PCONSOLE_GETCOMMANDHISTORY_MSG, SET_LAST_ERROR, SET_LAST_NT_ERROR, _CONSOLE_API_MSG::u, Unicode, _CONSOLE_GETCOMMANDHISTORY_MSG::Unicode, and _CONSOLE_GETCOMMANDHISTORY_MSG::UnicodeExe. Referenced by GetConsoleCommandHistoryA(), and GetConsoleCommandHistoryW().
|
|
Definition at line 930 of file client/cmdline.c. References FALSE, and GetConsoleCommandHistoryLengthInternal().
|
|
|
defined(BUILD_WOW6432)
Definition at line 920 of file client/cmdline.c. References GetConsoleCommandHistoryLengthInternal(), and TRUE.
|
|
defined(BUILD_WOW6432)
Definition at line 1010 of file client/cmdline.c. References Commands, GetConsoleCommandHistoryInternal(), and TRUE.
|
|
Definition at line 1256 of file client/cmdline.c. References DWORD, FALSE, FNAME_LENGTH, GetConsoleInputExeNameW(), n, NT_SUCCESS, NTSTATUS(), RtlInitUnicodeString(), RtlUnicodeStringToAnsiString(), SET_LAST_ERROR, Status, Unicode, and USHORT.
|
|
Definition at line 1288 of file client/cmdline.c. References DWORD, ExeNameBuffer, ExeNameCriticalSection, ExeNameLength, n, SET_LAST_ERROR, and TRUE. Referenced by GetConsoleInputExeNameA().
|
|
defined(BUILD_WOW6432)
Definition at line 1129 of file client/cmdline.c. References CHAR, DWORD, FALSE, and GetConsoleTitleInternal().
|
|
Definition at line 1070 of file client/cmdline.c. References _CONSOLE_GETTITLE_MSG::ConsoleHandle, ConsolepGetTitle, CsrAllocateCaptureBuffer(), CsrCaptureMessageBuffer(), CsrClientCallServer(), CsrFreeCaptureBuffer(), EXCEPTION_EXECUTE_HANDLER, GET_CONSOLE_HANDLE, NT_SUCCESS, NULL, PCONSOLE_GETTITLE_MSG, SET_LAST_ERROR, SET_LAST_NT_ERROR, _CONSOLE_GETTITLE_MSG::Title, _CONSOLE_GETTITLE_MSG::TitleLength, _CONSOLE_API_MSG::u, _CONSOLE_GETTITLE_MSG::Unicode, and Unicode. Referenced by GetConsoleTitleA(), and GetConsoleTitleW().
|
|
Definition at line 1147 of file client/cmdline.c. References CONSOLE_NAME_PATH_TERMINATOR, DWORD, GetConsoleTitleInternal(), and TRUE.
|
|
Definition at line 70 of file client/cmdline.c. References Buffer, ExeNameBuffer, ExeNameCriticalSection, ExeNameInitialized, ExeNameLength, and USHORT.
|
|
defined(BUILD_WOW64)
Definition at line 94 of file client/cmdline.c. References EXCEPTION_EXECUTE_HANDLER, FALSE, NULL, strlen(), TRUE, and USHORT. Referenced by AddConsoleAliasInternal(), ExpungeConsoleCommandHistoryInternal(), GetConsoleAliasesInternal(), GetConsoleAliasesLengthInternal(), GetConsoleAliasInternal(), GetConsoleCommandHistoryInternal(), GetConsoleCommandHistoryLengthInternal(), and SetConsoleNumberOfCommandsInternal().
|
|
Definition at line 39 of file client/cmdline.c. References CONSOLE_NAME_PATH_TERMINATOR, ExeNameBuffer, ExeNameCriticalSection, ExeNameInitialized, ExeNameLength, RtlInitializeCriticalSection(), StartDirBuffer, StartDirLength, and TRUE. Referenced by AllocConsole(), and ConDllInitialize().
|
|
defined(BUILD_WOW64)
Definition at line 1043 of file client/cmdline.c. References _CONSOLE_SETCOMMANDHISTORYMODE_MSG::ConsoleHandle, ConsolepSetCommandHistoryMode, CsrClientCallServer(), FALSE, _CONSOLE_SETCOMMANDHISTORYMODE_MSG::Flags, GET_CONSOLE_HANDLE, NT_SUCCESS, NULL, PCONSOLE_SETCOMMANDHISTORYMODE_MSG, SET_LAST_NT_ERROR, TRUE, and _CONSOLE_API_MSG::u.
|
|
Definition at line 1313 of file client/cmdline.c. References FALSE, NT_SUCCESS, NTSTATUS(), RtlAnsiStringToUnicodeString(), RtlInitAnsiString(), SET_LAST_ERROR, SetConsoleInputExeNameW(), Status, and Unicode.
|
|
Definition at line 1337 of file client/cmdline.c. References DWORD, ExeNameBuffer, ExeNameCriticalSection, ExeNameLength, FALSE, FNAME_LENGTH, n, SET_LAST_ERROR, TRUE, and USHORT. Referenced by SetConsoleInputExeNameA().
|
|
Definition at line 860 of file client/cmdline.c. References FALSE, and SetConsoleNumberOfCommandsInternal().
|
|
|
defined(BUILD_WOW6432)
Definition at line 848 of file client/cmdline.c. References SetConsoleNumberOfCommandsInternal(), and TRUE.
|
|
defined(BUILD_WOW6432)
Definition at line 1220 of file client/cmdline.c. References DWORD, EXCEPTION_EXECUTE_HANDLER, FALSE, SET_LAST_ERROR, SetConsoleTitleInternal(), and strlen().
|
|
defined(BUILD_WOW64)
Definition at line 1170 of file client/cmdline.c. References _CONSOLE_SETTITLE_MSG::ConsoleHandle, ConsolepSetTitle, CsrAllocateCaptureBuffer(), CsrCaptureMessageBuffer(), CsrClientCallServer(), CsrFreeCaptureBuffer(), FALSE, GET_CONSOLE_HANDLE, NT_SUCCESS, NULL, PCONSOLE_SETTITLE_MSG, SET_LAST_NT_ERROR, _CONSOLE_SETTITLE_MSG::Title, _CONSOLE_SETTITLE_MSG::TitleLength, TRUE, _CONSOLE_API_MSG::u, _CONSOLE_SETTITLE_MSG::Unicode, and Unicode. Referenced by SetConsoleTitleA(), and SetConsoleTitleW().
|
|
Definition at line 1238 of file client/cmdline.c. References DWORD, EXCEPTION_EXECUTE_HANDLER, FALSE, SET_LAST_ERROR, SetConsoleTitleInternal(), and TRUE.
|
|
Definition at line 33 of file client/cmdline.c. Referenced by GetConsoleAliasExesA(), GetConsoleAliasExesInternal(), GetConsoleAliasExesW(), GetConsoleInputExeNameW(), GetCurrentExeName(), InitExeName(), SetConsoleInputExeNameW(), and SetUpAppName(). |
|
Definition at line 32 of file client/cmdline.c. Referenced by GetConsoleInputExeNameW(), GetCurrentExeName(), InitExeName(), and SetConsoleInputExeNameW(). |
|
Definition at line 31 of file client/cmdline.c. Referenced by GetCurrentExeName(), and InitExeName(). |
|
Definition at line 34 of file client/cmdline.c. Referenced by GetConsoleInputExeNameW(), GetCurrentExeName(), InitExeName(), ReadChars(), ReadConsoleA(), ReadConsoleInternal(), ReadConsoleW(), SetConsoleInputExeNameW(), and SetUpAppName(). |
|
Definition at line 35 of file client/cmdline.c. Referenced by InitExeName(), and SetUpAppName(). |
|
Definition at line 36 of file client/cmdline.c. Referenced by InitExeName(), and SetUpAppName(). |