From 0afcb0871da6a09c7100ad4ab000ddeb11a305c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dag-Erling=20Sm=C3=B8rgrav?= Date: Sun, 24 Jun 2001 12:38:28 +0000 Subject: [PATCH] Constify, staticize and add a missing include; add WARNS?=2. Submitted by: Mike Barcroft MFC after: 2 weeks --- usr.sbin/chkgrp/Makefile | 1 + usr.sbin/chkgrp/chkgrp.c | 10 ++++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/usr.sbin/chkgrp/Makefile b/usr.sbin/chkgrp/Makefile index a7bfc548ced1..a1c3b5b7b0af 100644 --- a/usr.sbin/chkgrp/Makefile +++ b/usr.sbin/chkgrp/Makefile @@ -1,6 +1,7 @@ # $FreeBSD$ PROG= chkgrp +WARNS?= 2 MAN= chkgrp.8 .include diff --git a/usr.sbin/chkgrp/chkgrp.c b/usr.sbin/chkgrp/chkgrp.c index 7d1af60a4b22..2f93109620a9 100644 --- a/usr.sbin/chkgrp/chkgrp.c +++ b/usr.sbin/chkgrp/chkgrp.c @@ -34,10 +34,11 @@ static const char rcsid[] = #include #include #include +#include #include #include -void +static void usage(void) { fprintf(stderr, "usage: chkgrp [groupfile]\n"); @@ -47,9 +48,10 @@ usage(void) int main(int argc, char *argv[]) { - unsigned int len; - int n = 0, i, k, e = 0; - char *gfn, *line, *f[4], *p; + unsigned int i, len; + int n = 0, k, e = 0; + char *line, *f[4], *p; + const char *gfn; FILE *gf; /* check arguments */