reactos/reactos/base/shell/cmd/title.c
Jeffrey Morlan c49ed3a82c Remove the "LPTSTR cmd" argument to internal commands; there's no need for a command to be told its own name. It was only used in two places:
- a hack in cmd_mkdir that was already obsolete a decade ago
- to distinguish "echo" from "echo.", but that is the wrong way to implement this anyway. There's nothing particularly special about the period, "echo" is just one of those commands that is lenient about where its parameters begin, and when it echos a line, the first character (usually a space, but in the case of "echo." a period) is skipped.

svn path=/trunk/; revision=35647
2008-08-25 23:22:03 +00:00

37 lines
551 B
C

/*
* title.c - title internal command.
*
*
* History:
* 1999-02-11 Emanuele Aliberti
*
* 30-Apr-2005 (Magnus Olsen) <magnus@greatlord.com>)
* Remove all hardcode string to En.rc
*/
#include <precomp.h>
#ifdef INCLUDE_CMD_TITLE
INT cmd_title (LPTSTR param)
{
/* Do nothing if no args */
if (*param == _T('\0'))
return 0;
/* Asking help? */
if (!_tcsncmp(param, _T("/?"), 2))
{
ConOutResPaging(TRUE,STRING_TITLE_HELP);
return 0;
}
return SetConsoleTitle (param);
}
#endif /* def INCLUDE_CMD_TITLE */
/* EOF */