*/
-#include "config.h"
-
-#ifdef FEATURE_ALIASES
-
#include "precomp.h"
-#include <tchar.h>
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
+#ifdef FEATURE_ALIASES
typedef struct tagALIAS
{
* Added handling of multiple filenames.
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_ATTRIB
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
static VOID
PrintAttribute (LPTSTR pszPath, LPTSTR pszFile, BOOL bRecurse)
-/* $Id: batch.c,v 1.4 2004/08/15 22:15:23 chorns Exp $
+/* $Id: batch.c,v 1.5 2004/11/08 02:16:06 weiden Exp $
*
* BATCH.C - batch file processor for CMD.EXE.
*
* Fixes made to get "for" working.
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
-
-#include "batch.h"
/* The stack of current batch contexts.
* Redirection ready!
*/
-#include "config.h"
-
-#ifdef INCLUDE_CMD_BEEP
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include "batch.h"
+#ifdef INCLUDE_CMD_BEEP
INT cmd_beep (LPTSTR cmd, LPTSTR param)
-/* $Id: call.c,v 1.3 2004/08/15 22:15:23 chorns Exp $
+/* $Id: call.c,v 1.4 2004/11/08 02:16:06 weiden Exp $
*
* CALL.C - call internal batch command.
*
* Unicode and redirection safe!
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include "batch.h"
/*
*
*/
-#include "config.h"
-
-#ifdef INCLUDE_CMD_CHCP
-
#include "precomp.h"
-#include <tchar.h>
-#include <stdlib.h>
-#include <string.h>
+#ifdef INCLUDE_CMD_CHCP
INT CommandChcp (LPTSTR cmd, LPTSTR param)
{
* Fixed timeout.
*/
-#include "config.h"
-
-#ifdef INCLUDE_CMD_CHOICE
-
#include "precomp.h"
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-#include <tchar.h>
-#include "batch.h"
+#ifdef INCLUDE_CMD_CHOICE
#define GC_TIMEOUT -1
* Redirection ready!
*/
-#include "config.h"
-
-#ifdef INCLUDE_CMD_CLS
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
+#ifdef INCLUDE_CMD_CLS
INT cmd_cls (LPTSTR cmd, LPTSTR param)
{
-/* $Id: cmd.c,v 1.19 2004/08/22 20:47:20 hbirr Exp $
+/* $Id: cmd.c,v 1.20 2004/11/08 02:16:06 weiden Exp $
*
* CMD.C - command-line interface.
*
* Added ShellExecute call when all else fails to be able to "launch" any file.
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
-#include <stdio.h>
-#include <winnt.h>
-#include <winternl.h>
#ifndef NT_SUCCESS
#define NT_SUCCESS(StatCode) ((NTSTATUS)(StatCode) >= 0)
#endif
-#include "batch.h"
-
-#include <shellapi.h>
-
typedef NTSTATUS (STDCALL *NtQueryInformationProcessProc)(HANDLE, PROCESSINFOCLASS,
PVOID, ULONG, PULONG);
typedef NTSTATUS (STDCALL *NtReadVirtualMemoryProc)(HANDLE, PVOID, PVOID, ULONG, PULONG);
* Fixed problems when the screen was scrolled away.
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-
-#include "batch.h"
SHORT maxx;
* Unicode ready!
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
/* a list of all the internal commands, associating their command names */
-/* $Id: color.c,v 1.5 2004/08/15 22:15:23 chorns Exp $
+/* $Id: color.c,v 1.6 2004/11/08 02:16:06 weiden Exp $
*
* COLOR.C - color internal command.
*
* 4nt's syntax implemented
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_COLOR
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
static VOID ColorHelp (VOID)
-/* $Id: console.c,v 1.9 2004/11/02 20:47:05 weiden Exp $
+/* $Id: console.c,v 1.10 2004/11/08 02:16:06 weiden Exp $
*
* CONSOLE.C - console input/output functions.
*
* started
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <stdio.h>
-#include <stdarg.h>
-#include <string.h>
#define OUTPUT_BUFFER_SIZE 4096
-/* $Id: copy.c,v 1.5 2004/08/15 22:15:23 chorns Exp $
+/* $Id: copy.c,v 1.6 2004/11/08 02:16:06 weiden Exp $
*
* COPY.C -- copy internal command.
*
* Disabled prompting when used in batch mode.
*/
-#include "config.h"
-
-#ifdef INCLUDE_CMD_COPY
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
-#include <tchar.h>
-#include "batch.h"
+#ifdef INCLUDE_CMD_COPY
#define VERIFY 1 /* VERIFY Switch */
* Fixed date input bug.
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_DATE
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
static WORD awMonths[2][13] =
{
* Added prompt ("/P"), yes ("/Y") and wipe("/W") option.
*/
-#include "config.h"
-
-#ifdef INCLUDE_CMD_DEL
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
-#include <math.h>
-#include "batch.h"
+#ifdef INCLUDE_CMD_DEL
enum
*
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_DELAY
-#include "precomp.h"
-#include <tchar.h>
-#include <stdlib.h>
-
INT CommandDelay (LPTSTR cmd, LPTSTR param)
{
-/* $Id: dir.c,v 1.11 2004/08/15 22:15:23 chorns Exp $
+/* $Id: dir.c,v 1.12 2004/11/08 02:16:06 weiden Exp $
*
* DIR.C - dir internal command.
*
* Fix /w to print long names.
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_DIR
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <ctype.h>
/* flag definitions */
* Added DIRS command.
*/
-#include "config.h"
-
-#ifdef FEATURE_DIRECTORY_STACK
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
+#ifdef FEATURE_DIRECTORY_STACK
typedef struct tagDIRENTRY
{
-/* $Id: echo.c,v 1.4 2004/08/15 22:15:23 chorns Exp $
+/* $Id: echo.c,v 1.5 2004/11/08 02:16:06 weiden Exp $
*
* ECHO.C - internal echo commands.
*
* Implemented 'echo.' and 'echoerr.'.
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-
-#include "batch.h"
INT CommandEcho (LPTSTR cmd, LPTSTR param)
* Use FormatMessage() for error reports.
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <stdio.h>
-#include <stdarg.h>
#define INVALID_SWITCH _T("Invalid switch - /%c\n")
* Now expands lfn even when trailing " is omitted.
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
-#include <stdio.h>
#ifdef FEATURE_UNIX_FILENAME_COMPLETION
* code in other files fixed, too.
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
-
-#include "batch.h"
/*
* Started.
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_FREE
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdio.h>
-#include <ctype.h>
-
/*
* convert
* Added help text ("/?").
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
-#include "batch.h"
/*
*
*/
-#include "config.h"
-
-#ifdef FEATURE_HISTORY
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
+#ifdef FEATURE_HISTORY
typedef struct tagHISTORY
{
* IF DEFINED variable command
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
-#include "batch.h"
#define X_EXEC 1
* Improved chdir/cd command.
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
#ifdef INCLUDE_CMD_CHDIR
* Unicode ready!
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_LABEL
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
INT cmd_label (LPTSTR cmd, LPTSTR param)
{
* Unicode safe!
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
TCHAR cDateSeparator;
include $(TOOLS_PATH)/helper.mk
+include $(TOOLS_PATH)/depend.mk
+
# EOF
* Started.
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_MEMORY
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
/*
* convert
* Added PagePrompt() and FilePrompt().
*/
-#include "config.h"
-
#include "precomp.h"
-#include <ctype.h>
-#include <string.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <tchar.h>
/*
* Added "/N" option.
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_MOVE
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
#define OVERWRITE_NO 0
#define OVERWRITE_YES 1
* started - Paolo Pantaleo <paolopan@freemail.it>
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_MSGBOX
-#include "precomp.h"
-#include <ctype.h>
-#include <string.h>
-#include <tchar.h>
#define U_TYPE_INIT 0
* 24-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
* Fixed Win32 environment handling.
*/
-
-#include "config.h"
-
-#ifdef INCLUDE_CMD_PATH
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
+#ifdef INCLUDE_CMD_PATH
/* size of environment variable buffer */
#define ENV_BUFFER_SIZE 1024
* Unicode ready!
*/
-#include "config.h"
-
-#ifdef INCLUDE_CMD_PAUSE
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-
-#include "batch.h"
+#ifdef INCLUDE_CMD_PAUSE
/*
* Perform PAUSE command.
-#include "cmd.h"
#include <windows.h>
+#include <winnt.h>
+#include <winternl.h>
+#include <shellapi.h>
+
+#include <tchar.h>
+#include <ctype.h>
+#include <string.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <stdarg.h>
+
+#include "cmd.h"
+#include "config.h"
+#include "batch.h"
* 24-Jan-1999 (Eric Kohl <ekohl@abo.rhein-zeitung.de>)
* Fixed Win32 environment handling.
*/
-
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
/*
* print the command-line prompt
* Added new error AND output redirection "&>" and "&>>".
*/
-#include "config.h"
+#include "precomp.h"
#ifdef FEATURE_REDIRECTION
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
static BOOL
IsRedirection (TCHAR c)
* Implemented basic rename code.
*/
-#include "config.h"
-
-#ifdef INCLUDE_CMD_RENAME
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-#include "batch.h"
+#ifdef INCLUDE_CMD_RENAME
enum
{
*
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_SCREEN
-#include "precomp.h"
-#include <tchar.h>
-#include <stdlib.h>
-#include <ctype.h>
-
INT CommandScreen (LPTSTR cmd, LPTSTR param)
{
* Fixed little bug.
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_SET
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-
/* initial size of environment variable buffer */
#define ENV_BUFFER_SIZE 1024
* Unicode and redirection safe!
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-
-#include "batch.h"
/*
* Started.
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_START
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <stdlib.h>
-#include <ctype.h>
INT cmd_start (LPTSTR first, LPTSTR rest)
#include "precomp.h"
-#include <ctype.h>
-#include <tchar.h>
-
-
#define _B FOREGROUND_BLUE
#define _G FOREGROUND_GREEN
#define _R FOREGROUND_RED
* Fixed time input bug.
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_TIME
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
-
static BOOL ParseTime (LPTSTR s)
{
* started - Paolo Pantaleo <paolopan@freemail.it>
*/
-#include "config.h"
-
-#ifdef INCLUDE_CMD_TIMER
#include "precomp.h"
-#include <ctype.h>
-#include <string.h>
-#include <tchar.h>
+#ifdef INCLUDE_CMD_TIMER
#define NCS_NOT_SPECIFIED -1
* 1999-02-11 Emanuele Aliberti
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_TITLE
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-
INT cmd_title (LPTSTR cmd, LPTSTR param)
{
* Added multiple file support (copied from y.c)
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_TYPE
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-
INT cmd_type (LPTSTR cmd, LPTSTR param)
{
* New version info and some output changes.
*/
-#include "config.h"
-
#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-#include <ctype.h>
VOID ShortVersion (VOID)
* Unicode and redirection ready!
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_VERIFY
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-
/* global verify flag */
static BOOL bVerify = FALSE;
* Redirection ready!
*/
-#include "config.h"
+#include "precomp.h"
#ifdef INCLUDE_CMD_VOL
-#include "precomp.h"
-#include <tchar.h>
-#include <string.h>
-
static INT
PrintVolumeHeader (LPTSTR pszRootPath)
*
*/
-#include "config.h"
-
#include "precomp.h"
-#include <string.h>
-#include <stdlib.h>
/* initial size of environment variable buffer */
-/* $Id: window.c,v 1.2 2004/08/15 22:15:23 chorns Exp $
+/* $Id: window.c,v 1.3 2004/11/08 02:16:06 weiden Exp $
*
* WINDOW.C - activate & window internal commands.
*
*/
-#include "config.h"
+#include "precomp.h"
#if ( defined(INCLUDE_CMD_WINDOW) || defined(INCLUDE_CMD_ACTIVATE) )
-#include "precomp.h"
-#include <stdlib.h>
-#include <string.h>
-#include <tchar.h>
-
#define A_MIN 0x01
#define A_MAX 0x02