1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-17 15:27:36 +00:00

Constify, add a prototype, and set WARNS=2.

Submitted by:	Mike Barcroft <mike@q9media.com>
Reviewed by:	md5(1)
This commit is contained in:
Dima Dorfman 2001-06-24 18:43:33 +00:00
parent dfe60c7914
commit 167ce4fb00
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=78714
2 changed files with 3 additions and 3 deletions

View File

@ -1,7 +1,7 @@
# $FreeBSD$ # $FreeBSD$
PROG= lptcontrol PROG= lptcontrol
WARNS?= 2
MAN= lptcontrol.8 MAN= lptcontrol.8
CFLAGS+= -Wall
.include <bsd.prog.mk> .include <bsd.prog.mk>

View File

@ -56,7 +56,7 @@ static const char rcsid[] =
#define USE_EXT_MODE 2 #define USE_EXT_MODE 2
#define USE_STD_MODE 3 #define USE_STD_MODE 3
static void usage() static void usage(void)
{ {
fprintf(stderr, "usage: lptcontrol -i | -p | -s | -e [-d device]\n"); fprintf(stderr, "usage: lptcontrol -i | -p | -s | -e [-d device]\n");
exit(1); exit(1);
@ -77,7 +77,7 @@ int main (int argc, char * argv[])
{ {
int opt; int opt;
int irq_status = IRQ_INVALID; int irq_status = IRQ_INVALID;
char *device = DEFAULT_DEVICE; const char *device = DEFAULT_DEVICE;
while((opt = getopt(argc, argv, "ipesd:")) != -1) while((opt = getopt(argc, argv, "ipesd:")) != -1)
switch(opt) { switch(opt) {