Deleted Added
full compact
rpc_tblout.c (200462) rpc_tblout.c (222080)
1/*
2 * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
3 * unrestricted use provided that this legend is included on all tape
4 * media and as a part of the software program in whole or part. Users
5 * may copy or modify Sun RPC without charge, but are not authorized
6 * to license or distribute it to anyone else except as part of a product or
7 * program developed by the user.
8 *

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

30#if 0
31#ifndef lint
32#ident "@(#)rpc_tblout.c 1.11 93/07/05 SMI"
33static char sccsid[] = "@(#)rpc_tblout.c 1.4 89/02/22 (C) 1988 SMI";
34#endif
35#endif
36
37#include <sys/cdefs.h>
1/*
2 * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
3 * unrestricted use provided that this legend is included on all tape
4 * media and as a part of the software program in whole or part. Users
5 * may copy or modify Sun RPC without charge, but are not authorized
6 * to license or distribute it to anyone else except as part of a product or
7 * program developed by the user.
8 *

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

30#if 0
31#ifndef lint
32#ident "@(#)rpc_tblout.c 1.11 93/07/05 SMI"
33static char sccsid[] = "@(#)rpc_tblout.c 1.4 89/02/22 (C) 1988 SMI";
34#endif
35#endif
36
37#include <sys/cdefs.h>
38__FBSDID("$FreeBSD: head/usr.bin/rpcgen/rpc_tblout.c 200462 2009-12-13 03:14:06Z delphij $");
38__FBSDID("$FreeBSD: head/usr.bin/rpcgen/rpc_tblout.c 222080 2011-05-18 20:52:52Z benl $");
39
40/*
41 * rpc_tblout.c, Dispatch table outputter for the RPC protocol compiler
42 * Copyright (C) 1989, Sun Microsystems, Inc.
43 */
44#include <err.h>
45#include <stdio.h>
46#include <string.h>

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

98 locase(def->def_name), vp->vers_num);
99 /* print the table header */
100 f_print(fout, tbl_hdr, progvers);
101
102 if (nullproc(vp->procs)) {
103 expected = 0;
104 } else {
105 expected = 1;
39
40/*
41 * rpc_tblout.c, Dispatch table outputter for the RPC protocol compiler
42 * Copyright (C) 1989, Sun Microsystems, Inc.
43 */
44#include <err.h>
45#include <stdio.h>
46#include <string.h>

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

98 locase(def->def_name), vp->vers_num);
99 /* print the table header */
100 f_print(fout, tbl_hdr, progvers);
101
102 if (nullproc(vp->procs)) {
103 expected = 0;
104 } else {
105 expected = 1;
106 f_print(fout, null_entry);
106 fputs(null_entry, fout);
107 }
108 for (proc = vp->procs; proc != NULL; proc = proc->next) {
109 current = atoi(proc->proc_num);
110 if (current != expected++) {
111 f_print(fout,
112 "\n/*\n * WARNING: table out of order\n */\n");
113 if (warning == 0) {
114 warnx("WARNING %s table is out of order", progvers);

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

136 /* do we have to do something special for newstyle */
137 printit( proc->args.decls->decl.prefix,
138 proc->args.decls->decl.type );
139 /* result info */
140 printit(proc->res_prefix, proc->res_type);
141 }
142
143 /* print the table trailer */
107 }
108 for (proc = vp->procs; proc != NULL; proc = proc->next) {
109 current = atoi(proc->proc_num);
110 if (current != expected++) {
111 f_print(fout,
112 "\n/*\n * WARNING: table out of order\n */\n");
113 if (warning == 0) {
114 warnx("WARNING %s table is out of order", progvers);

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

136 /* do we have to do something special for newstyle */
137 printit( proc->args.decls->decl.prefix,
138 proc->args.decls->decl.type );
139 /* result info */
140 printit(proc->res_prefix, proc->res_type);
141 }
142
143 /* print the table trailer */
144 f_print(fout, tbl_end);
144 fputs(tbl_end, fout);
145 f_print(fout, tbl_nproc, progvers, progvers, progvers);
146 }
147}
148
149static void
150printit(const char *prefix, const char *type)
151{
152 int len;

--- 20 unchanged lines hidden ---
145 f_print(fout, tbl_nproc, progvers, progvers, progvers);
146 }
147}
148
149static void
150printit(const char *prefix, const char *type)
151{
152 int len;

--- 20 unchanged lines hidden ---