mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-01 04:13:38 +00:00
cmd: Output error messages to stderr instead of stdout where appropriate.
This commit is contained in:
parent
40c783fcc1
commit
aee397a317
|
@ -1124,7 +1124,7 @@ void WCMD_for (WCHAR *p, CMD_LIST **cmdList) {
|
|||
/* Process the input file */
|
||||
if (input == INVALID_HANDLE_VALUE) {
|
||||
WCMD_print_error ();
|
||||
WCMD_output (WCMD_LoadMessage(WCMD_READFAIL), item);
|
||||
WCMD_output_stderr(WCMD_LoadMessage(WCMD_READFAIL), item);
|
||||
errorlevel = 1;
|
||||
return; /* FOR loop aborts at first failure here */
|
||||
|
||||
|
@ -1539,7 +1539,7 @@ void WCMD_if (WCHAR *p, CMD_LIST **cmdList) {
|
|||
WCMD_parameter(s, 1, &command, NULL);
|
||||
}
|
||||
else {
|
||||
WCMD_output (WCMD_LoadMessage(WCMD_SYNTAXERR));
|
||||
WCMD_output_stderr(WCMD_LoadMessage(WCMD_SYNTAXERR));
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -1055,7 +1055,7 @@ void WCMD_run_program (WCHAR *command, int called) {
|
|||
if (strchrW(param1, '.') != NULL) extensionsupplied = TRUE;
|
||||
if (strlenW(param1) >= MAX_PATH)
|
||||
{
|
||||
WCMD_output_asis(WCMD_LoadMessage(WCMD_LINETOOLONG));
|
||||
WCMD_output_asis_stderr(WCMD_LoadMessage(WCMD_LINETOOLONG));
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -1836,9 +1836,9 @@ WCHAR *WCMD_ReadAndParseLine(const WCHAR *optionalcmd, CMD_LIST **output,
|
|||
|
||||
/* Handle truncated input - issue warning */
|
||||
if (strlenW(extraSpace) == MAXSTRING -1) {
|
||||
WCMD_output_asis(WCMD_LoadMessage(WCMD_TRUNCATEDLINE));
|
||||
WCMD_output_asis(extraSpace);
|
||||
WCMD_output_asis(newline);
|
||||
WCMD_output_asis_stderr(WCMD_LoadMessage(WCMD_TRUNCATEDLINE));
|
||||
WCMD_output_asis_stderr(extraSpace);
|
||||
WCMD_output_asis_stderr(newline);
|
||||
}
|
||||
|
||||
/* Replace env vars if in a batch context */
|
||||
|
|
Loading…
Reference in a new issue