summaryrefslogtreecommitdiffstats
path: root/sbin/reboot/reboot.c
diff options
context:
space:
mode:
authorcharnier <charnier@FreeBSD.org>1998-07-15 06:51:38 +0000
committercharnier <charnier@FreeBSD.org>1998-07-15 06:51:38 +0000
commitc4fa54fec2bb8f4f294b0569acc334b431c530e8 (patch)
treefd8123d03e64d7016cc6adc0fa0e1a788a2b9f80 /sbin/reboot/reboot.c
parent259a90a05b5995a148aa435efc140c260cb2696b (diff)
downloadFreeBSD-src-c4fa54fec2bb8f4f294b0569acc334b431c530e8.zip
FreeBSD-src-c4fa54fec2bb8f4f294b0569acc334b431c530e8.tar.gz
Correct use of .Nm. Add rcsid. -Wall. Add -p flag in usage string (was missing).
Diffstat (limited to 'sbin/reboot/reboot.c')
-rw-r--r--sbin/reboot/reboot.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/sbin/reboot/reboot.c b/sbin/reboot/reboot.c
index 6fb6a01..ca3e729 100644
--- a/sbin/reboot/reboot.c
+++ b/sbin/reboot/reboot.c
@@ -29,30 +29,33 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
- *
- * $Id: reboot.c,v 1.5 1997/06/16 06:43:13 charnier Exp $
*/
#ifndef lint
-static char copyright[] =
+static const char copyright[] =
"@(#) Copyright (c) 1980, 1986, 1993\n\
The Regents of the University of California. All rights reserved.\n";
#endif /* not lint */
#ifndef lint
+#if 0
static char sccsid[] = "@(#)reboot.c 8.1 (Berkeley) 6/5/93";
+#endif
+static const char rcsid[] =
+ "$Id$";
#endif /* not lint */
#include <sys/reboot.h>
+#include <sys/types.h>
#include <signal.h>
-#include <pwd.h>
+#include <err.h>
#include <errno.h>
+#include <libutil.h>
+#include <pwd.h>
#include <syslog.h>
-#include <unistd.h>
#include <stdio.h>
-#include <stdlib.h>
#include <string.h>
-#include <err.h>
+#include <unistd.h>
void usage __P((void));
@@ -178,6 +181,6 @@ restart:
void
usage()
{
- (void)fprintf(stderr, "usage: %s [-nq]\n", dohalt ? "halt" : "reboot");
+ (void)fprintf(stderr, "usage: %s [-npq]\n", dohalt ? "halt" : "reboot");
exit(1);
}
OpenPOWER on IntegriCloud