summaryrefslogtreecommitdiffstats
path: root/libexec/revnetgroup
diff options
context:
space:
mode:
authorwpaul <wpaul@FreeBSD.org>1996-08-04 19:17:15 +0000
committerwpaul <wpaul@FreeBSD.org>1996-08-04 19:17:15 +0000
commitfdc849d17cd0834f78b62409c6f536d5cc0cce43 (patch)
tree227b179a421412f929471083aa03bf1585c9642a /libexec/revnetgroup
parent8aa520d461ac887af299bb0754d69039a931a062 (diff)
downloadFreeBSD-src-fdc849d17cd0834f78b62409c6f536d5cc0cce43.zip
FreeBSD-src-fdc849d17cd0834f78b62409c6f536d5cc0cce43.tar.gz
Use err() instead of perror()/exit() and remember to #include <errno.h>
and <err.h>.
Diffstat (limited to 'libexec/revnetgroup')
-rw-r--r--libexec/revnetgroup/revnetgroup.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/libexec/revnetgroup/revnetgroup.c b/libexec/revnetgroup/revnetgroup.c
index e92f3c0..70c0a2c 100644
--- a/libexec/revnetgroup/revnetgroup.c
+++ b/libexec/revnetgroup/revnetgroup.c
@@ -35,16 +35,18 @@
* Center for Telecommunications Research
* Columbia University, New York City
*
- * $Id: revnetgroup.c,v 1.1.1.1 1995/10/26 16:25:29 wpaul Exp $
+ * $Id: revnetgroup.c,v 1.2 1996/05/12 17:17:45 wpaul Exp $
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <errno.h>
+#include <err.h>
#include "hash.h"
#ifndef lint
-static const char rcsid[] = "$Id$";
+static const char rcsid[] = "$Id: revnetgroup.c,v 1.2 1996/05/12 17:17:45 wpaul Exp $";
#endif
#define LINSIZ 1024
@@ -120,8 +122,7 @@ main(argc, argv)
if (strcmp(netgroup, "-")) {
if ((fp = fopen(netgroup, "r")) == NULL) {
- perror(netgroup);
- exit(1);
+ err(1,netgroup);
}
} else {
fp = stdin;
OpenPOWER on IntegriCloud