xref: /csrg-svn/usr.sbin/timed/timedc/cmdtab.c (revision 33123)
123721Sgusella /*
223721Sgusella  * Copyright (c) 1983 Regents of the University of California.
3*33123Sbostic  * All rights reserved.
4*33123Sbostic  *
5*33123Sbostic  * Redistribution and use in source and binary forms are permitted
6*33123Sbostic  * provided that this notice is preserved and that due credit is given
7*33123Sbostic  * to the University of California at Berkeley. The name of the University
8*33123Sbostic  * may not be used to endorse or promote products derived from this
9*33123Sbostic  * software without specific prior written permission. This software
10*33123Sbostic  * is provided ``as is'' without express or implied warranty.
1123721Sgusella  */
1223721Sgusella 
1323721Sgusella #ifndef lint
14*33123Sbostic static char sccsid[] = "@(#)cmdtab.c	2.4 (Berkeley) 12/23/87";
15*33123Sbostic #endif /* not lint */
1623721Sgusella 
1723721Sgusella #include "timedc.h"
1823721Sgusella 
1923721Sgusella int	clockdiff(), help(), msite(), quit(), testing(), tracing();
2023721Sgusella 
2123721Sgusella char	clockdiffhelp[] =	"measures clock differences between machines";
2223721Sgusella char	helphelp[] =		"gets help on commands";
2323721Sgusella char	msitehelp[] =		"finds location of master";
2423721Sgusella char	quithelp[] =		"exits timedc";
2523721Sgusella char	testinghelp[] =		"causes election timers to expire";
2623721Sgusella char	tracinghelp[] =		"turns tracing on or off";
2723721Sgusella 
2823721Sgusella struct cmd cmdtab[] = {
2923721Sgusella 	{ "clockdiff",	clockdiffhelp,	clockdiff,	0 },
3028862Sbloom 	{ "election",	testinghelp,	testing,	1 },
3123721Sgusella 	{ "help",	helphelp,	help,		0 },
3223721Sgusella 	{ "msite",	msitehelp,	msite,		0 },
3323721Sgusella 	{ "quit",	quithelp,	quit,		0 },
3428862Sbloom 	{ "trace",	tracinghelp,	tracing,	1 },
3523721Sgusella 	{ "?",		helphelp,	help,		0 },
3623721Sgusella };
3723721Sgusella 
3823721Sgusella int	NCMDS = sizeof (cmdtab) / sizeof (cmdtab[0]);
39