Fix whitespace (part 3/x) (convert tabs into 4-space indent).

svn path=/trunk/; revision=59379
This commit is contained in:
Hermès Bélusca-Maïto 2013-06-30 00:08:43 +00:00
parent 9b6dc5bd15
commit 6437619ff3
25 changed files with 3026 additions and 3010 deletions

View file

@ -25,8 +25,8 @@
* 24-Jan-1998 Eric Kohl
* Redirection safe!
*
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*
* 02-Feb-2008 (Christoph von Wittich) <christoph_vw@reactos.org>)
* rewrote alias handling for doskey compat

View file

@ -205,7 +205,6 @@ RemoveAssociation(LPTSTR extension)
INT CommandAssoc (LPTSTR param)
{
/* print help */
if (!_tcsncmp (param, _T("/?"), 2))
{

View file

@ -28,8 +28,8 @@
* 23-Jan-1999 Eric Kohl
* Added handling of multiple filenames.
*
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"
@ -109,7 +109,7 @@ PrintAttribute (LPTSTR pszPath, LPTSTR pszFile, BOOL bRecurse)
static VOID
ChangeAttribute (LPTSTR pszPath, LPTSTR pszFile, DWORD dwMask,
ChangeAttribute(LPTSTR pszPath, LPTSTR pszFile, DWORD dwMask,
DWORD dwAttrib, BOOL bRecurse, BOOL bDirectories)
{
WIN32_FIND_DATA findData;

View file

@ -20,8 +20,8 @@
* 20-Jan-1999 (Eric Kohl)
* Redirection ready!
*
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -24,8 +24,8 @@
* 20-Jan-1999 (Eric Kohl)
* Unicode and redirection safe!
*
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -7,8 +7,8 @@
* 23-Dec-1998 (Eric Kohl)
* Started.
*
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -13,9 +13,8 @@
* 26 Sep 1999 (Paolo Pantaleo)
* Fixed timeout.
*
* 02 Apr 2005 (Magnus Olsen
* Remove Hardcode string so
* they can be translate
* 02 Apr 2005 (Magnus Olsen)
* Remove hardcoded strings so that they can be translated.
*
*/

View file

@ -22,8 +22,8 @@
* 20-Jan-1998 (Eric Kohl)
* Redirection ready!
*
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 02-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -19,8 +19,10 @@
#include "precomp.h"
/* a list of all the internal commands, associating their command names */
/* to the functions to process them */
/*
* A list of all the internal commands, associating their command names
* to the functions to process them.
*/
COMMAND cmds[] =

View file

@ -16,8 +16,8 @@
* 14-Oct-1999 (Paolo Pantaleo <paolopan@freemail.it>)
* 4nt's syntax implemented.
*
* 03-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Move all hardcoded strings to En.rc.
* 03-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Move all hardcoded strings in En.rc.
*/
#include "precomp.h"

View file

@ -22,8 +22,8 @@
* 13-Jul-2000 (Eric Kohl)
* Implemented 'echo.' and 'echoerr.'.
*
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -16,8 +16,8 @@
* 02-Feb-1999 (Eric Kohl)
* Use FormatMessage() for error reports.
*
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -26,8 +26,8 @@
* Implemented preservation of echo flag. Some other for related
* code in other files fixed, too.
*
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -7,8 +7,8 @@
* 01-Sep-1999 (Eric Kohl)
* Started.
*
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"
@ -79,7 +79,6 @@ PrintDiskInfo (LPTSTR szDisk)
uliSize = dwSecPerCl * dwBytPerSec * (ULONGLONG)dwFreeCl;
ConvertULargeInteger(uliSize, szFree, 40, TRUE);
ConOutResPrintf(STRING_FREE_HELP1, szDrive, szVolume, szSerial, szTotal, szUsed, szFree);
}

View file

@ -22,8 +22,8 @@
* 27-Jan-1999 (Eric Kohl)
* Added help text ("/?").
*
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -25,8 +25,8 @@
* 17-Feb-2001 (ea)
* IF DEFINED variable command
*
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*
*/

View file

@ -13,8 +13,8 @@
* 19-Jan-1998 (Eric Kohl)
* Unicode ready!
*
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -7,8 +7,8 @@
* 01-Sep-1999 (Eric Kohl)
* Started.
*
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 28-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"

View file

@ -6,8 +6,8 @@
* 25 Aug 1999
* started - Paolo Pantaleo <paolopan@freemail.it>
*
* 30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"
@ -24,7 +24,6 @@
INT CommandMsgbox (LPTSTR param)
{
//used to parse command line
LPTSTR tmp;
@ -84,7 +83,6 @@ INT CommandMsgbox (LPTSTR param)
#endif
}
//skip spaces
while(_istspace(*param))
param++;

View file

@ -11,7 +11,8 @@ static const TCHAR OpString[][3] = { _T("&"), _T("||"), _T("&&"), _T("|") };
static const TCHAR RedirString[][3] = { _T("<"), _T(">"), _T(">>") };
static const TCHAR *const IfOperatorString[] = {
static const TCHAR *const IfOperatorString[] =
{
_T("cmdextversion"),
_T("defined"),
_T("errorlevel"),
@ -35,8 +36,15 @@ static BOOL IsSeparator(TCHAR Char)
return _istspace(Char) || (Char && _tcschr(STANDARD_SEPS, Char));
}
enum { TOK_END, TOK_NORMAL, TOK_OPERATOR, TOK_REDIRECTION,
TOK_BEGIN_BLOCK, TOK_END_BLOCK };
enum
{
TOK_END,
TOK_NORMAL,
TOK_OPERATOR,
TOK_REDIRECTION,
TOK_BEGIN_BLOCK,
TOK_END_BLOCK
};
static BOOL bParseError;
static BOOL bLineContinuations;
@ -56,9 +64,11 @@ static TCHAR ParseChar()
return CurChar = 0;
restart:
/* Although CRs can be injected into a line via an environment
/*
* Although CRs can be injected into a line via an environment
* variable substitution, the parser ignores them - they won't
* even separate tokens. */
* even separate tokens.
*/
do
Char = *ParsePos++;
while (Char == _T('\r'));
@ -88,8 +98,10 @@ static void ParseError()
bParseError = TRUE;
}
/* Yes, cmd has a Lexical Analyzer. Whenever the parser gives an "xxx was
* unexpected at this time." message, it shows what the last token read was */
/*
* Yes, cmd has a Lexical Analyzer. Whenever the parser gives an "xxx was
* unexpected at this time." message, it shows what the last token read was.
*/
static int ParseToken(TCHAR ExtraEnd, TCHAR *Separators)
{
TCHAR *Out = CurrentToken;
@ -266,6 +278,7 @@ static BOOL ParseRedirection(REDIRECTION **List)
_tcscpy(Redir->Filename, Tok);
*List = Redir;
return TRUE;
fail:
ParseError();
FreeRedirection(*List);
@ -411,8 +424,10 @@ condition_done:
return Cmd;
}
/* Parse a FOR command.
* Syntax is: FOR [options] %var IN (list) DO command */
/*
* Parse a FOR command.
* Syntax is: FOR [options] %var IN (list) DO command
*/
static PARSED_COMMAND *ParseFor(void)
{
PARSED_COMMAND *Cmd = cmd_alloc(sizeof(PARSED_COMMAND));
@ -730,8 +745,10 @@ ParseCommand(LPTSTR Line)
}
/* Reconstruct a parse tree into text form; used for echoing
* batch file commands and FOR instances. */
/*
* Reconstruct a parse tree into text form; used for echoing
* batch file commands and FOR instances.
*/
VOID
EchoCommand(PARSED_COMMAND *Cmd)
{
@ -819,9 +836,11 @@ EchoCommand(PARSED_COMMAND *Cmd)
}
}
/* "Unparse" a command into a text form suitable for passing to CMD /C.
/*
* "Unparse" a command into a text form suitable for passing to CMD /C.
* Used for pipes. This is basically the same thing as EchoCommand, but
* writing into a string instead of to standard output. */
* writing into a string instead of to standard output.
*/
TCHAR *
Unparse(PARSED_COMMAND *Cmd, TCHAR *Out, TCHAR *OutEnd)
{
@ -829,9 +848,11 @@ Unparse(PARSED_COMMAND *Cmd, TCHAR *Out, TCHAR *OutEnd)
PARSED_COMMAND *Sub;
REDIRECTION *Redir;
/* Since this function has the annoying requirement that it must avoid
/*
* Since this function has the annoying requirement that it must avoid
* overflowing the supplied buffer, define some helper macros to make
* this less painful */
* this less painful.
*/
#define CHAR(Char) { \
if (Out == OutEnd) return NULL; \
*Out++ = Char; }

View file

@ -22,8 +22,8 @@
* 24-Jan-1999 (Eric Kohl)
* Fixed Win32 environment handling.
*
* 30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
#include "precomp.h"
@ -35,7 +35,6 @@
INT cmd_path (LPTSTR param)
{
if (!_tcsncmp (param, _T("/?"), 2))
{
ConOutResPaging(TRUE,STRING_PATH_HELP1);

View file

@ -30,13 +30,12 @@
* ?? Extend to include functionality of CHOICE if switch chars
* specified.
*
* 30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
* 30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>
* Remove all hardcoded strings in En.rc
*/
INT cmd_pause (LPTSTR param)
{
TRACE ("cmd_pause: \'%s\')\n", debugstr_aw(param));
if (!_tcsncmp (param, _T("/?"), 2))