Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/xlint/lint1 Use setprogname() in main().
details: https://anonhg.NetBSD.org/src/rev/2fe3ec5bfe58
branches: trunk
changeset: 521513:2fe3ec5bfe58
user: tv <tv%NetBSD.org@localhost>
date: Thu Jan 31 19:33:50 2002 +0000
description:
Use setprogname() in main().
diffstat:
usr.bin/xlint/lint1/main1.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diffs (45 lines):
diff -r fe7a5a7c22ed -r 2fe3ec5bfe58 usr.bin/xlint/lint1/main1.c
--- a/usr.bin/xlint/lint1/main1.c Thu Jan 31 19:33:27 2002 +0000
+++ b/usr.bin/xlint/lint1/main1.c Thu Jan 31 19:33:50 2002 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: main1.c,v 1.11 2002/01/29 02:43:38 tv Exp $ */
+/* $NetBSD: main1.c,v 1.12 2002/01/31 19:33:50 tv Exp $ */
/*
* Copyright (c) 1994, 1995 Jochen Pohl
@@ -32,8 +32,8 @@
*/
#include <sys/cdefs.h>
-#ifndef lint
-__RCSID("$NetBSD: main1.c,v 1.11 2002/01/29 02:43:38 tv Exp $");
+#if defined(__RCSID) && !defined(lint)
+__RCSID("$NetBSD: main1.c,v 1.12 2002/01/31 19:33:50 tv Exp $");
#endif
#include <sys/types.h>
@@ -123,6 +123,8 @@
int c;
char *ptr;
+ setprogname(argv[0]);
+
ERR_ZERO(&msgset);
while ((c = getopt(argc, argv, "abcdeghmprstuvwyzFX:")) != -1) {
switch (c) {
@@ -206,7 +208,6 @@
static void
usage(void)
{
-
(void)fprintf(stderr,
"Usage: %s [-abcdeghmprstuvwyzF] [-X <id>[,<id>]... src dest\n",
getprogname());
@@ -216,7 +217,6 @@
void
norecover(void)
{
-
/* cannot recover from previous errors */
error(224);
exit(1);
Home |
Main Index |
Thread Index |
Old Index