hesinfo.c (f1bb2cd2aa7488657658fbc09aae2ead579049ab) hesinfo.c (d397408818fbfa179246fb327659e3fb29ffff31)
1/* $NetBSD: hesinfo.c,v 1.1 1999/01/25 22:45:55 lukem Exp $ */
2
3/* Copyright 1988, 1996 by the Massachusetts Institute of Technology.
4 *
5 * Permission to use, copy, modify, and distribute this
6 * software and its documentation for any purpose and without
7 * fee is hereby granted, provided that the above copyright
8 * notice appear in all copies and that both that copyright

--- 19 unchanged lines hidden (view full) ---

28#include <errno.h>
29#include <hesiod.h>
30#include <stdio.h>
31#include <stdlib.h>
32#include <string.h>
33#include <unistd.h>
34
35int main(int, char **);
1/* $NetBSD: hesinfo.c,v 1.1 1999/01/25 22:45:55 lukem Exp $ */
2
3/* Copyright 1988, 1996 by the Massachusetts Institute of Technology.
4 *
5 * Permission to use, copy, modify, and distribute this
6 * software and its documentation for any purpose and without
7 * fee is hereby granted, provided that the above copyright
8 * notice appear in all copies and that both that copyright

--- 19 unchanged lines hidden (view full) ---

28#include <errno.h>
29#include <hesiod.h>
30#include <stdio.h>
31#include <stdlib.h>
32#include <string.h>
33#include <unistd.h>
34
35int main(int, char **);
36extern char *__progname;
37
38int
39main(argc, argv)
40 int argc;
41 char **argv;
42{
43 char **list, **p, *bindname, *name, *type;
44 int lflag = 0, errflg = 0, bflag = 0, c;

--- 8 unchanged lines hidden (view full) ---

53 bflag = 1;
54 break;
55 default:
56 errflg++;
57 break;
58 }
59 }
60 if (argc - optind != 2 || errflg) {
36
37int
38main(argc, argv)
39 int argc;
40 char **argv;
41{
42 char **list, **p, *bindname, *name, *type;
43 int lflag = 0, errflg = 0, bflag = 0, c;

--- 8 unchanged lines hidden (view full) ---

52 bflag = 1;
53 break;
54 default:
55 errflg++;
56 break;
57 }
58 }
59 if (argc - optind != 2 || errflg) {
61 fprintf(stderr, "Usage: %s [-bl] name type\n", __progname);
60 fprintf(stderr, "usage: hesinfo [-bl] name type\n");
62 fprintf(stderr, "\t-l selects long format\n");
63 fprintf(stderr, "\t-b also does hes_to_bind conversion\n");
64 exit(2);
65 }
66 name = argv[optind];
67 type = argv[optind + 1];
68
69 if (hesiod_init(&context) < 0) {

--- 47 unchanged lines hidden ---
61 fprintf(stderr, "\t-l selects long format\n");
62 fprintf(stderr, "\t-b also does hes_to_bind conversion\n");
63 exit(2);
64 }
65 name = argv[optind];
66 type = argv[optind + 1];
67
68 if (hesiod_init(&context) < 0) {

--- 47 unchanged lines hidden ---