History log of /freebsd-current/usr.bin/rpcgen/rpc_svcout.c
Revision Date Author Comments
# 5b31cc94 23-Nov-2023 Warner Losh <imp@FreeBSD.org>

sccs: Manual changes

For the uncommon items: Go through the tree and remove sccs tags that
didn't fit any nice pattern. If in the neighborhood, other SCM tags were
removed when they were detritis of long-ago CVS somehow in the early
mists of the project. Some adjacent copyrights stringswere removed (they
duplicated the copyright notices in the file). This also removed
non-standard formations of omission of SCCS tags (usually by adding an
extra #if 0 somewhere.

After this commit, a number of strings tagged with the 'what' @(#)
prefix remain, but they are primarily copyright notices.

Sponsored by: Netflix


# bdcbfde3 23-Nov-2023 Warner Losh <imp@FreeBSD.org>

usr.bin: Remove ancient SCCS tags.

Remove ancient SCCS tags from the tree, automated scripting, with two
minor fixup to keep things compiling. All the common forms in the tree
were removed with a perl script.

Sponsored by: Netflix


# 1d386b48 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: one-line .c pattern

Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/


# 4fa1e855 04-Dec-2022 John Baldwin <jhb@FreeBSD.org>

rpcgen: Unindent a line not guarded by if (mtflag).

mtflag is used to add pthread mutex locking around operations to make
them thread-safe. Setting the state to _SERVED is not conditional on
locking.

Reviewed by: imp, emaste
Differential Revision: https://reviews.freebsd.org/D37541


# f5ab496e 12-Jan-2017 Pedro F. Giffuni <pfg@FreeBSD.org>

rpcgen(1): Check getrlimit() return for generated code.

Obtained from: NetBSD (CVS rev 1.27, 1.28)
MFC after: 1 week


# 80c7cc1c 15-Apr-2016 Pedro F. Giffuni <pfg@FreeBSD.org>

Cleanup unnecessary semicolons from utilities we all love.


# bf70bece 19-Oct-2012 Ed Schouten <ed@FreeBSD.org>

More -Wmissing-variable-declarations fixes.

In addition to adding `static' where possible:

- bin/date: Move `retval' into extern.h to make it visible to date.c.
- bin/ed: Move globally used variables into ed.h.
- sbin/camcontrol: Move `verbose' into camcontrol.h and fix shadow warnings.
- usr.bin/calendar: Remove unneeded variables.
- usr.bin/chat: Make `line' local instead of global.
- usr.bin/elfdump: Comment out unneeded function.
- usr.bin/rlogin: Use _Noreturn instead of __dead2.
- usr.bin/tset: Pull `Ospeed' into extern.h.
- usr.sbin/mfiutil: Put global variables in mfiutil.h.
- usr.sbin/pkg: Remove unused `os_corres'.
- usr.sbin/quotaon, usr.sbin/repquota: Remove unused `qfname'.


# 487ac9ac 30-Dec-2011 Ulrich Spörlein <uqs@FreeBSD.org>

Spelling fixes for usr.bin/


# 9bde021a 18-May-2011 Ben Laurie <benl@FreeBSD.org>

Fix clang warnings.

Note: these were actually bugs (printf with no format string).

Approved by: philip (mentor)


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# fe0506d7 09-Mar-2010 Marcel Moolenaar <marcel@FreeBSD.org>

Create the altix project branch. The altix project will add support
for the SGI Altix 350 to FreeBSD/ia64. The hardware used for porting
is a two-module system, consisting of a base compute module and a
CPU expansion module. SGI's NUMAFlex architecture can be an excellent
platform to test CPU affinity and NUMA-aware features in FreeBSD.


# d7f03759 19-Oct-2008 Ulf Lilleengen <lulf@FreeBSD.org>

- Import the HEAD csup code which is the basis for the cvsmode work.


# d458f462 12-Aug-2008 Doug Rabson <dfr@FreeBSD.org>

When generating thread-safe server code, handle procedures with void return
types correctly.


# f7504c33 23-Aug-2007 Xin LI <delphij@FreeBSD.org>

Use POSIX mutex instead of Solaris ones. This makes generation
of threaded RPC servers to work out of the box.

Spotted by: Changming Sun <changming at staff.sina.com.cn>
Sponsored by: SINA Corporation
Approved by: re (kensmith)


# 03fec0bd 16-Jun-2007 Stefan Eßer <se@FreeBSD.org>

Never define the generated rpc server main function with storage type
"static". The header file generated by "rpcgen -h" will always declare
it as extern, leading to a "static after extern" error being issued by
gcc-4.2. This caused only a warning in gcc-3.x, but it has been wrong
all the time.

This change does not modify the code generated by "rpcgen -m", it only
affects rpcgen used to generate server stubs with a local main function.

This is the minimal patch. It does not remove the now obsolete "storage"
parameter from write_program() and write_programs() in an attempt to keep
differences to other systems' versions of rpcgen as small as possible.


# 99b671f5 17-May-2006 Robert Watson <rwatson@FreeBSD.org>

In change 1.15, an arbitrary setting of the max RPC record size to
RPC_MAXDATASIZE was introduced. This is believed to have been debugging
code committed accidentally, although I've been unable to reach the
committer to confirm this. The effect was to limit the size of RPCs on
TCP and UDP to 9k, well below the default protocol limits in the libc
rpc code. This change simply removes these introduced limits, falling
back on the libc definitions.

PR: 88856
Reported by: Keith Bostic <bostic at sleepycat dot com>
Testing by: Susan LoVerso <sue at loverso dot southborough dot ma dot us>
Reveiwed by: cel, rees
Review timeout: alfred, mbr
MFC after: 2 weeks


# e390e3af 13-Nov-2005 David Malone <dwmalone@FreeBSD.org>

Use ANSI definitions.
Avoid using extern by declaring shared functions in header files.
Const poision.


# 1e72f11f 02-Sep-2005 Stefan Farfeleder <stefanf@FreeBSD.org>

Use socklen_t variables when passing sizes to getsockname() and
getsockopt().


# adcd7386 02-Sep-2005 Stefan Farfeleder <stefanf@FreeBSD.org>

Fix a syntax error in the generated code when invoked with -P. Note that
the generated code still doesn't compile as we lack tinfo, t_getinfo and
friends.


# 896cdc31 02-Sep-2005 Stefan Farfeleder <stefanf@FreeBSD.org>

Stop generating the `register' keyword.


# 15df5e2d 02-Sep-2005 Stefan Farfeleder <stefanf@FreeBSD.org>

Don't generate K&R C code. The -C flag is kept for backwards compatibility.
Also remove the SIG_PF macro, there is no need to cast closedown.


# d0cc804b 31-Aug-2005 Stefan Farfeleder <stefanf@FreeBSD.org>

- Use prototypes in headers.
- Include rpc_scan.h before rpc_util.h for the tok_kind enum.
- Nuke unused declarations.


# 63f17371 31-May-2005 Stefan Farfeleder <stefanf@FreeBSD.org>

Move #ident into #if 0.


# bcb53b16 16-Jan-2003 Martin Blapp <mbr@FreeBSD.org>

Implement nonblocking tpc-connections. rpcgen -m does still
produce backcompatible code.

Reviewed by: rwatson
Obtained from: NetBSD
MFC after: 1 day


# 75863a6d 20-Jul-2002 Philippe Charnier <charnier@FreeBSD.org>

Removal of spaces at EOL. Add __FBSDID. New function xmalloc, xrealloc,
xstrdup. There is a crash() function that do cleaning before exiting the
program. The new functions are wrappers that make use of crash() in case
of allocation failure. warn, exit -> err.

Reviewed by: alfred


# 40ad8885 14-Jul-2002 Alfred Perlstein <alfred@FreeBSD.org>

- TI-RPC is now the default again for code generation.

- As before, inetd support support is turned of per default.
Code for inetd can be made with -I.

- Support for ``transport monitors'' and the NLSPROVIDER env
variable is still there , even if their use is not clear in
non TLI stream based systems like Free-/NetBSD. It can be activated
with -P.

- There are a few corrections in rpcgen.1 and usage function to conform
to the code. Added and documented -P

- I removed the #ifdefs checks for Free-/NetBSD since we are the only
ones who use this code. MaxOS X may have the same limitations as
we have, so this code will correctly build for them.

- Generate correct cflags.

Submitted by: mbr, Jean-Luc Richier <Jean-Luc.Richier@imag.fr>
PR: bin/29175, misc/27816


# 7dac28cf 09-May-2002 Dag-Erling Smørgrav <des@FreeBSD.org>

Back out part of previous commit - K&R doesn't have const.


# 0081eff3 08-May-2002 Dag-Erling Smørgrav <des@FreeBSD.org>

Make _msgout take a const char * rather than a char *.

Sponsored by: DARPA, NAI Labs


# d3cb5ded 21-Mar-2002 Warner Losh <imp@FreeBSD.org>

remove __P


# c0e30a2b 18-Jul-2001 Kris Kennaway <kris@FreeBSD.org>

Embed $FreeBSD$ as an rcsid[]


# 69c828c6 05-Jul-2001 Kris Kennaway <kris@FreeBSD.org>

Don't generate syslog() statements which have format string vulnerabilities.

MFC after: 1 week


# 8360efbd 18-Mar-2001 Alfred Perlstein <alfred@FreeBSD.org>

Bring in a hybrid of SunSoft's transport-independent RPC (TI-RPC) and
associated changes that had to happen to make this possible as well as
bugs fixed along the way.

Bring in required TLI library routines to support this.

Since we don't support TLI we've essentially copied what NetBSD
has done, adding a thin layer to emulate direct the TLI calls
into BSD socket calls.

This is mostly from Sun's tirpc release that was made in 1994,
however some fixes were backported from the 1999 release (supposedly
only made available after this porting effort was underway).

The submitter has agreed to continue on and bring us up to the
1999 release.

Several key features are introduced with this update:
Client calls are thread safe. (1999 code has server side thread
safe)
Updated, a more modern interface.

Many userland updates were done to bring the code up to par with
the recent RPC API.

There is an update to the pthreads library, a function
pthread_main_np() was added to emulate a function of Sun's threads
library.

While we're at it, bring in NetBSD's lockd, it's been far too
long of a wait.

New rpcbind(8) replaces portmap(8) (supporting communication over
an authenticated Unix-domain socket, and by default only allowing
set and unset requests over that channel). It's much more secure
than the old portmapper.

Umount(8), mountd(8), mount_nfs(8), nfsd(8) have also been upgraded
to support TI-RPC and to support IPV6.

Umount(8) is also fixed to unmount pathnames longer than 80 chars,
which are currently truncated by the Kernel statfs structure.

Submitted by: Martin Blapp <mb@imp.ch>
Manpage review: ru
Secure RPC implemented by: wpaul


# c513aafe 02-Aug-1998 Bruce Evans <bde@FreeBSD.org>

Fixed printf format errors.


# 526195ad 12-Jul-1996 Jordan K. Hubbard <jkh@FreeBSD.org>

General -Wall warning cleanup, part I.
Submitted-By: Kent Vander Velden <graphix@iastate.edu>


# ff49530f 12-Dec-1995 Bill Paul <wpaul@FreeBSD.org>

Clean up. (I hope I'm doing this right.)

Update rpcgen with the one from the TI-RPC 2.3 distribution.

Note that when built for FreeBSD, this version of rpcgen assumes
backwards compatibility mode by default. This means that it will produce
ONCRPC 4.0 compatible code unless otherwise instructed, instead of the
other way around.

One incompatibility has also been worked around: this rpcgen normally
always emits an '#include <stropts.h>' directive whether you select
backwards compatibility mode or not. We don't have STREAMS, so this
behavior has been changed: now it will only emit this line if run in TI-RPC
mode.

The 'generate output files in current directory instead of the
directory where the protocol definition file lives' hack from the
original rpcgen has been preserved.

Notable new features:

- Can be used to generate RPC servers that can be launched
from port monitors such as inetd(5).

- Can generate ANSI C code.

- Can generate sample client and server top-level programs and
makefiles in addition to the usual client and server stubs.

- Can generate inline XDR routines.


# ee4f614e 12-Dec-1995 Bill Paul <wpaul@FreeBSD.org>

Import a newer and more functional version of rpcgen.

Obtained from: the Sun TI-RPC 2.3 source distribution


# 7799f52a 30-May-1995 Rodney W. Grimes <rgrimes@FreeBSD.org>

Remove trailing whitespace.


# 5ec07232 04-Mar-1995 Nate Williams <nate@FreeBSD.org>

Fix rpcgen so that generated files are written to the current working
directory (instead of the same directory as the source files) and that
#includes in those files do not contain the path to the source file.

Obtained from: J.T. Conklin via NetBSD


# 4e115012 07-Aug-1994 Garrett Wollman <wollman@FreeBSD.org>

Move RPC stub generator program over from 1.1.5.

Submitted by: Original work in 1.x by J. T. Conklin.