mirror of
https://github.com/reactos/reactos.git
synced 2025-05-18 00:31:27 +00:00
- Fix build
- Partly revert 57718 svn path=/trunk/; revision=57719
This commit is contained in:
parent
38b84d3f65
commit
59ce999f95
4 changed files with 10 additions and 10 deletions
|
@ -3,6 +3,6 @@ set_rc_compiler()
|
||||||
|
|
||||||
add_executable(doskey doskey.c doskey.rc)
|
add_executable(doskey doskey.c doskey.rc)
|
||||||
|
|
||||||
set_module_type(doskey win32cui)
|
set_module_type(doskey win32cui UNICODE)
|
||||||
add_importlibs(doskey user32 msvcrt kernel32)
|
add_importlibs(doskey user32 msvcrt kernel32)
|
||||||
add_cd_file(TARGET doskey DESTINATION reactos/system32 FOR all)
|
add_cd_file(TARGET doskey DESTINATION reactos/system32 FOR all)
|
||||||
|
|
|
@ -72,19 +72,19 @@ static INT SetMacro(LPWSTR definition)
|
||||||
temp = *nameend;
|
temp = *nameend;
|
||||||
*nameend = L'\0';
|
*nameend = L'\0';
|
||||||
/* Don't allow spaces in the name, since such a macro would be unusable */
|
/* Don't allow spaces in the name, since such a macro would be unusable */
|
||||||
if (!wcschr(name, L' ') && AddConsoleAlias(name, text, pszExeName))
|
if (!wcschr(name, L' ') && AddConsoleAliasW(name, text, pszExeName))
|
||||||
return 0;
|
return 0;
|
||||||
*nameend = temp;
|
*nameend = temp;
|
||||||
}
|
}
|
||||||
|
|
||||||
LoadString(GetModuleHandle(NULL), IDS_INVALID_MACRO_DEF, szStringBuf, MAX_STRING);
|
LoadStringW(GetModuleHandle(NULL), IDS_INVALID_MACRO_DEF, szStringBuf, MAX_STRING);
|
||||||
wprintf(szStringBuf, definition);
|
wprintf(szStringBuf, definition);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
static VOID PrintMacros(LPWSTR pszExeName, LPWSTR Indent)
|
static VOID PrintMacros(LPWSTR pszExeName, LPWSTR Indent)
|
||||||
{
|
{
|
||||||
DWORD Length = GetConsoleAliasesLength(pszExeName);
|
DWORD Length = GetConsoleAliasesLengthW(pszExeName);
|
||||||
PBYTE AliasBuf;
|
PBYTE AliasBuf;
|
||||||
WCHAR *Alias;
|
WCHAR *Alias;
|
||||||
WCHAR *AliasEnd;
|
WCHAR *AliasEnd;
|
||||||
|
@ -96,7 +96,7 @@ static VOID PrintMacros(LPWSTR pszExeName, LPWSTR Indent)
|
||||||
Alias = (WCHAR *)AliasBuf;
|
Alias = (WCHAR *)AliasBuf;
|
||||||
AliasEnd = (WCHAR *)&AliasBuf[Length];
|
AliasEnd = (WCHAR *)&AliasBuf[Length];
|
||||||
|
|
||||||
if (GetConsoleAliases(Alias, Length * sizeof(BYTE), pszExeName))
|
if (GetConsoleAliasesW(Alias, Length * sizeof(BYTE), pszExeName))
|
||||||
for (; Alias < AliasEnd; Alias += wcslen(Alias) + 1)
|
for (; Alias < AliasEnd; Alias += wcslen(Alias) + 1)
|
||||||
wprintf(L"%s%s\n", Indent, Alias);
|
wprintf(L"%s%s\n", Indent, Alias);
|
||||||
|
|
||||||
|
@ -117,7 +117,7 @@ static VOID PrintAllMacros(VOID)
|
||||||
ExeName = (WCHAR *)ExeNameBuf;
|
ExeName = (WCHAR *)ExeNameBuf;
|
||||||
ExeNameEnd = (WCHAR *)&ExeNameBuf[Length];
|
ExeNameEnd = (WCHAR *)&ExeNameBuf[Length];
|
||||||
|
|
||||||
if (GetConsoleAliasExes(ExeName, Length * sizeof(BYTE)))
|
if (GetConsoleAliasExesW(ExeName, Length * sizeof(BYTE)))
|
||||||
{
|
{
|
||||||
for (; ExeName < ExeNameEnd; ExeName += wcslen(ExeName) + 1)
|
for (; ExeName < ExeNameEnd; ExeName += wcslen(ExeName) + 1)
|
||||||
{
|
{
|
||||||
|
@ -199,7 +199,7 @@ wmain(VOID)
|
||||||
|
|
||||||
/* Get the full command line using GetCommandLine(). We can't just use argv,
|
/* Get the full command line using GetCommandLine(). We can't just use argv,
|
||||||
* because then a parameter like "gotoroot=cd \" wouldn't be passed completely. */
|
* because then a parameter like "gotoroot=cd \" wouldn't be passed completely. */
|
||||||
pArgEnd = GetCommandLine();
|
pArgEnd = GetCommandLineW();
|
||||||
hKernel32 = LoadLibraryW(L"kernel32.dll");
|
hKernel32 = LoadLibraryW(L"kernel32.dll");
|
||||||
|
|
||||||
/* Get function pointers */
|
/* Get function pointers */
|
||||||
|
@ -222,7 +222,7 @@ wmain(VOID)
|
||||||
|
|
||||||
if (!wcscmp(pArgStart, L"/?"))
|
if (!wcscmp(pArgStart, L"/?"))
|
||||||
{
|
{
|
||||||
LoadString(GetModuleHandle(NULL), IDS_HELP, szStringBuf, MAX_STRING);
|
LoadStringW(GetModuleHandle(NULL), IDS_HELP, szStringBuf, MAX_STRING);
|
||||||
wprintf(szStringBuf);
|
wprintf(szStringBuf);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,7 +41,7 @@ add_executable(diskpart
|
||||||
uniqueid.c
|
uniqueid.c
|
||||||
diskpart.rc)
|
diskpart.rc)
|
||||||
|
|
||||||
set_module_type(diskpart win32cui)
|
set_module_type(diskpart win32cui UNICODE)
|
||||||
add_importlibs(diskpart user32 msvcrt kernel32)
|
add_importlibs(diskpart user32 msvcrt kernel32)
|
||||||
if(MSVC)
|
if(MSVC)
|
||||||
add_importlibs(diskpart ntdll)
|
add_importlibs(diskpart ntdll)
|
||||||
|
|
|
@ -31,7 +31,7 @@ ShowHeader(VOID)
|
||||||
DWORD comp_size = MAX_STRING_SIZE;
|
DWORD comp_size = MAX_STRING_SIZE;
|
||||||
|
|
||||||
/* Get the name of the computer for us and change the value of comp_name */
|
/* Get the name of the computer for us and change the value of comp_name */
|
||||||
GetComputerName(szComputerName, &comp_size);
|
GetComputerNameW(szComputerName, &comp_size);
|
||||||
|
|
||||||
/* TODO: Remove this section of code when program becomes stable enough for production use. */
|
/* TODO: Remove this section of code when program becomes stable enough for production use. */
|
||||||
wprintf(L"\n*WARNING*: This program is incomplete and may not work properly.\n");
|
wprintf(L"\n*WARNING*: This program is incomplete and may not work properly.\n");
|
||||||
|
|
Loading…
Reference in a new issue