313103 |
02-Feb-2017 |
asomers |
MFC r311160, r311210, r311288, r311292, r311298, r311340
r311160: misc minor fixes in mpr(4)
sys/dev/mpr/mpr_sas.c * Fix a potential null pointer dereference (CID 1305731) * Check for overrun of the ccb_scsiio.cdb_io.cdb_bytes buffer (CID 1211934)
sys/dev/mpr/mpr_sas_lsi.c * Nullify a dangling pointer in mprsas_get_sata_identify * Fix a memory leak in mprsas_SSU_to_SATA_devices (CID 1211935)
Reported by: Coverity (partially) CID: 1305731 1211934 1211935 Reviewed by: slm MFC after: 4 weeks Sponsored by: Spectra Logic Corp Differential Revision: https://reviews.freebsd.org/D8880
r311210: Quell Coverity for diskinfo(8)
* CID 1198994: Don't run the speed disk on a disk with no sectors * CID 1011442: Don't call close(2) if open(2) fails * CID 1011161: Use snprintf instead of sprintf * CID 1009825: Check the return value of lseek
Reported by: Coverity CID: 1198994 1011442 1011161 1009825 MFC after: 4 weeks Sponsored by: Spectra Logic Corp
r311288: Delete dead code in chat(8)
It's always been dead, ever since first import in 1994. It's still dead in OpenBSD's version, too.
Reported by: Coverity CID: 270586 MFC after: 4 weeks Sponsored by: Spectra Logic Corp
r311292: Remove dead code in rpc_parse.c
It's been dead ever since it was imported from TI-RPC in 1995. The dead code is still present in Illumos today, but was removed from NetBSD in 2006.
Reported by: Coverity CID: 270097 Obtained from: NetBSD MFC after: 4 weeks Sponsored by: Spectra Logic Corp
r311298: Remove dead code in dhclient(8)
The offending code has been dead ever since the import from OpenBSD in r195805. OpenBSD later deleted that entire function.
Reported by: Coverity CID: 500059 MFC after: 4 weeks Sponsored by: Spectra Logic Corp
r311340: Misc Coverity fixes for tail(1)
CID 1006402: Initialize stack variable CID 271580: Don't leak memory when ENOMEM.
Reported by: Coverity CID: 271580 1006402 MFC after: 4 weeks Sponsored by: Spectra Logic Corp |
312386 |
18-Jan-2017 |
pfg |
MFC r311947, r311981:
rpcgen(1): Avoid unused variable warning on generated code.
Avoid "unused variable 'i'" warnings in generated .c files by only emitting the "int i;" for non-opaque arrays. Opaque arrays use xdr_opaque() rather than iterating over the array.
Obtained from: OpenBSD (CVS rev 1.28)
rpcgen(1): Check getrlimit() return for generated code.
Obtained from: NetBSD (CVS rev 1.27, 1.28) |
309505 |
03-Dec-2016 |
ngie |
MFC r298183,r304226:
r298183 (by araujo):
Use NULL for pointers.
strrchr(3) will return NULL if the character does not appears in the string.
r304226 (by araujo):
Use nitems() from sys/param.h. |
267444 |
13-Jun-2014 |
bdrewery |
MFC r267174:
Fix some rpcgen sample file issues.
PR: 185582 |
256281 |
10-Oct-2013 |
gjb |
Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation
|
241737 |
19-Oct-2012 |
ed |
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'.
|
231101 |
06-Feb-2012 |
dim |
In usr.bin/rpcgen/rpc_main.c, use execvp(3) instead of execv(3), so rpcgen will search the current PATH for the preprocessor. This makes it possible to run a preprocessor built during the cross-tools stage of buildworld.
MFC after: 1 week
|
231080 |
06-Feb-2012 |
dim |
Amend r231079 by properly shifting up the existing arguments in rpc_main.c's insarg() function. I had forgotten to put this in my patch queue, sorry.
Pointy hat to: me MFC after: 1 week
|
231079 |
06-Feb-2012 |
dim |
Let rpcgen(1) support an environment variable RPCGEN_CPP to find the C preprocessor to run. Previously, it always ran /usr/bin/cpp, unless you used the -Y option, and even then you could not set the basename. It also attempted to run /usr/ccs/lib/cpp for SVR4 compatibility, but this is obsolete, and has been removed.
Note that setting RPCGEN_CPP to a command with arguments is supported, though the command line parsing is simplistic. However, setting it to e.g. "gcc46 -E" or "clang -E" will lead to problems, because both gcc and clang in -E mode will consider files with unknown extensions (such as .x) as object files, and attempt to link them.
This could be worked around by also adding "-x c", but it is much safer to set RPCGEN_CPP to e.g. "cpp46" or "clang-cpp" instead.
MFC after: 1 week
|
231054 |
05-Feb-2012 |
dim |
In usr.bin/rpcgen/rpc_main.c, properly check the return value of strlcpy(), in addition to checking that of strlcat().
MFC after: 1 week
|
229403 |
03-Jan-2012 |
ed |
Replace index() and rindex() calls with strchr() and strrchr().
The index() and rindex() functions were marked LEGACY in the 2001 revision of POSIX and were subsequently removed from the 2008 revision. The strchr() and strrchr() functions are part of the C standard.
This makes the source code a lot more consistent, as most of these C files also call into other str*() routines. In fact, about a dozen already perform strchr() calls.
|
228992 |
30-Dec-2011 |
uqs |
Spelling fixes for usr.bin/
|
223922 |
11-Jul-2011 |
delphij |
Use strlcpy().
MFC after: 1 month
|
222080 |
18-May-2011 |
benl |
Fix clang warnings.
Note: these were actually bugs (printf with no format string).
Approved by: philip (mentor)
|
207733 |
06-May-2010 |
delphij |
Plug a memory leak.
MFC after: 2 weeks
|
201386 |
02-Jan-2010 |
ed |
Build usr.bin/ with WARNS=6 by default.
Also add some missing $FreeBSD$ to keep svn happy.
|
201382 |
02-Jan-2010 |
ed |
ANSIfy various tools in usr.bin/.
Most of these tools properly build at WARNS=6, except for their K&R function declarations. Fix this, so we can bump WARNS as well.
|
200462 |
13-Dec-2009 |
delphij |
Revert most part of 200420 as requested, as more review and polish is needed.
|
200420 |
11-Dec-2009 |
delphij |
Remove unneeded header includes from usr.bin/ except contributed code.
Tested with: make universe
|
181630 |
12-Aug-2008 |
dfr |
When generating thread-safe server code, handle procedures with void return types correctly.
|
173761 |
20-Nov-2007 |
jb |
Generate code that doesn't fail gcc 4.2's strict aliasing test.
|
171932 |
23-Aug-2007 |
delphij |
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)
|
171931 |
23-Aug-2007 |
delphij |
sysent.h is installed as sys/sysent.h, so reflect it.
Approved by: re (kensmith) Spotted by: Changming Sun <changming at staff.sina.com.cn> Sponsored by: SINA Corporation
|
170825 |
16-Jun-2007 |
se |
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.
|
158713 |
17-May-2006 |
rwatson |
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
|
152415 |
14-Nov-2005 |
rodrigc |
Eliminate coredump problem introduced by last commit.
Noticed by: Guido van Rooij <guido at gvr dot org>
|
152407 |
14-Nov-2005 |
rodrigc |
Eliminate build breakage due to warnings about const.
|
152398 |
13-Nov-2005 |
dwmalone |
Use ANSI definitions. Avoid using extern by declaring shared functions in header files. Const poision.
|
149741 |
02-Sep-2005 |
stefanf |
In version 1.8 I botched findval()'s type, fix.
|
149733 |
02-Sep-2005 |
stefanf |
Use socklen_t variables when passing sizes to getsockname() and getsockopt().
|
149731 |
02-Sep-2005 |
stefanf |
The appropriate argument is -K -1, not -k -1.
|
149729 |
02-Sep-2005 |
stefanf |
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.
|
149710 |
02-Sep-2005 |
stefanf |
Stop generating the `register' keyword.
|
149709 |
02-Sep-2005 |
stefanf |
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.
|
149695 |
01-Sep-2005 |
stefanf |
Only write the dispatch table function prototypes to the header if the -h flag was specified. If all files are generated at once, those functions are static and shouldn't appear in the header.
PR: 84450 Reviewed by: alfred
|
149682 |
31-Aug-2005 |
stefanf |
- Use prototypes in headers. - Include rpc_scan.h before rpc_util.h for the tok_kind enum. - Nuke unused declarations.
|
149680 |
31-Aug-2005 |
stefanf |
Rename the variable `inline' to `inline_size'.
|
146833 |
31-May-2005 |
stefanf |
Move #ident into #if 0.
|
141614 |
10-Feb-2005 |
alfred |
back out 1.7 changes, unneeded and possibly wrong.
|
141604 |
10-Feb-2005 |
stefanf |
Let the generated code include <string.h> instead of <memory.h>.
|
141152 |
02-Feb-2005 |
alfred |
Modify rpcgen -t output to something that's a lot more useful in today's modern "no sir, not today" compilers.
Basically, when building the table:
use NULL instead of 0, use braces around array initializers, case the function pointers to xdrproc_t, don't cast function pointers that do not need casting.
MFC After: 1 week
|
140284 |
15-Jan-2005 |
ru |
Markup nit.
|
131491 |
02-Jul-2004 |
ru |
Mechanically kill hard sentence breaks.
|
128817 |
02-May-2004 |
smkelly |
- style(9) improvements courtesy of bde. - Revise the former commit to behave nicer on filenames containing multiple '.' characters. - Prevent the generation of macros starting with "__".
|
128810 |
02-May-2004 |
smkelly |
Teach rpcgen to generate .h files properly when the input filename contains characters that can't be used in preprocessor macros.
PR: bin/66156 Submitted by: K S Braunsdorf <rpc@ksb.npcguild.org>
|
116578 |
19-Jun-2003 |
mbr |
Fix broken -a functionality.
Reviewed by: phk Submitted by: Martin Kammerhofer <mkamm@gmx.net> PR: 53451
MFC: 1 week
|
109363 |
16-Jan-2003 |
mbr |
Implement nonblocking tpc-connections. rpcgen -m does still produce backcompatible code.
Reviewed by: rwatson Obtained from: NetBSD MFC after: 1 day
|
107276 |
26-Nov-2002 |
ru |
mdoc(7) police: markup polishing.
Approved by: re
|
100441 |
21-Jul-2002 |
charnier |
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
|
99980 |
14-Jul-2002 |
alfred |
WARNS=2
|
99979 |
14-Jul-2002 |
alfred |
- 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
|
96246 |
09-May-2002 |
des |
Back out part of previous commit - K&R doesn't have const.
|
96219 |
08-May-2002 |
des |
Make _msgout take a const char * rather than a char *.
Sponsored by: DARPA, NAI Labs
|
95124 |
20-Apr-2002 |
charnier |
Use `The .Nm utility'
|
92921 |
22-Mar-2002 |
imp |
remove __P
|
86318 |
13-Nov-2001 |
alfred |
Have rpcgen output the prototypes for the dispatch tables
|
81956 |
20-Aug-2001 |
kris |
Don't overflow a buffer from command line arguments.
MFC after: 2 weeks
|
79880 |
19-Jul-2001 |
kris |
Embed $FreeBSD$ as an rcsid[]
|
79755 |
15-Jul-2001 |
dd |
Remove whitespace at EOL.
|
79295 |
05-Jul-2001 |
kris |
Don't generate syslog() statements which have format string vulnerabilities.
MFC after: 1 week
|
75497 |
13-Apr-2001 |
alfred |
Turn -b (BSD socket compat mode) back on by default, as we don't have TLI/XTI
|
74848 |
27-Mar-2001 |
ru |
MAN[1-9] -> MAN.
|
74462 |
19-Mar-2001 |
alfred |
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
|
70899 |
10-Jan-2001 |
obrien |
Have rpcgen actually tell us what cpp it is looking for (as it would if we were SVR%).
|
70849 |
09-Jan-2001 |
obrien |
Use /usr/bin/cpp as on NetBSD, not /usr/libexec/cpp.
|
68963 |
20-Nov-2000 |
ru |
mdoc(7) police: use the new features of the Nm macro.
|
67191 |
16-Oct-2000 |
brian |
Include sys/types.h
|
57670 |
01-Mar-2000 |
sheldonh |
Remove single-space hard sentence breaks. These degrade the quality of the typeset output, tend to make diffs harder to read and provide bad examples for new-comers to mdoc.
|
57193 |
14-Feb-2000 |
chris |
Reduce the number of args to .%T to an acceptable number by removing the `Nm' command from the line. This means that %T will actually work.
|
56412 |
23-Jan-2000 |
mpp |
Fxi various man pages to stop abusing the .Bx macro to generate the string "FreeBSD". Use the .Fx macro instead. Also did some minor re-wording/formatting to work around a deficiency with the .Fx macro when it comes to puncuation characters other than periods and commas.
|
52671 |
30-Oct-1999 |
phantom |
mdoc(7)'fy
|
50477 |
28-Aug-1999 |
peter |
$Id$ -> $FreeBSD$
|
48792 |
12-Jul-1999 |
nik |
Add $Id$, to make it simpler for members of the translation teams to track.
The $Id$ line is normally at the bottom of the main comment block in the man page, separated from the rest of the manpage by an empty comment, like so;
.\" $Id$ .\"
If the immediately preceding comment is a @(#) format ID marker than the the $Id$ will line up underneath it with no intervening blank lines. Otherwise, an additional blank line is inserted.
Approved by: bde
|
48566 |
04-Jul-1999 |
billf |
Clean up some ambiguous nested if/elses.
|
42286 |
04-Jan-1999 |
bde |
Backed out previous commit. The bug was in rev.1.49 of src/Makefile.inc1, so it can't be completely fixed here. Putting -I paths to the current headers in CFLAGS is more likely to break things than fix them, since there is no reason why current headers should work with old libraries. Other Makefiles that do this may only work because they are not used early in the bootstrap. However, the usual problem with errno being defined in terms of a nonexistent library doesn't seem to occur here, since we don't reference errno.
|
42275 |
04-Jan-1999 |
chuckr |
Fix a build problem when upgrading from 9 month old sources. There's a circular dependency problem, wherein rpcgen depends on the latest includes, but those same includes depend on rpcgen to build include/rpcsvc. This was causing the build or librpcsvc to fail (like I said, only on upgrades of 9 month old sources).
If there's stylistic problems, tell me, I'll learn and fix them. I did a buildworld with this, it should be safe.
|
39642 |
25-Sep-1998 |
obrien |
include <pthread.h>
Submitted by: Alexander Leidinger <netchild@wurzelausix.CS.Uni-SB.DE>
|
38952 |
08-Sep-1998 |
obrien |
Add support for the RPC 64-bit integer type ``hyper''.
|
38022 |
02-Aug-1998 |
bde |
Fixed printf format errors.
|
36700 |
06-Jun-1998 |
thepish |
PR: docs/5628 Submitted by: MITSUNAGA Noriaki mitchy@er.ams.eng.osaka-u.ac.jp Correct formatting error in display of the "-i size" option description section.
|
34147 |
07-Mar-1998 |
jb |
Fix a #ifndef that became a #ifdef and changed the default behaviour of rpcgen.
Noticed by: bde
|
32523 |
15-Jan-1998 |
jb |
Add #ifdefs for __NetBSD__ in the rest of the places where __FreeBSD__ is defined so that this program behaves the same when built with either set of tools. The only difference is where the pre-processor is found. And that is a bug - it should check the CPP environment variable and the path before just assuming that the compiled in path is OK. I guess we should be using -Y ${WORLDPATH}/usr/bin/cpp during a bootstrap build.
|
32362 |
09-Jan-1998 |
jb |
Add __NetBSD__ in a couple of places to allow this program to compile under NetBSD, but behave like FreeBSD. For the time being, look for NetBSD's cpp in /usr/bin.
|
30909 |
03-Nov-1997 |
charnier |
Convert to mdoc.
|
27935 |
06-Aug-1997 |
charnier |
Use err(3), cosmetic in usage(), remove `cmdname'.
|
17142 |
12-Jul-1996 |
jkh |
General -Wall warning cleanup, part I. Submitted-By: Kent Vander Velden <graphix@iastate.edu>
|
14040 |
12-Feb-1996 |
mpp |
Minor cleanup of the rpc man pages to silence manck.
|
13835 |
02-Feb-1996 |
mpp |
Correct some manual page cross reference errors. E.g. su is a section one man page, not section eight. This is the first round of such changes and only fixes man pages in manual section one.
|
12798 |
13-Dec-1995 |
wpaul |
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.
|
12796 |
13-Dec-1995 |
wpaul |
This commit was generated by cvs2svn to compensate for changes in r12795, which included commits to RCS files with non-trunk default branches.
|
8874 |
30-May-1995 |
rgrimes |
Remove trailing whitespace.
|
8526 |
15-May-1995 |
ache |
End of listcan be not marked, fix it Submitted by: Kai Vorma <vode@snakemail.hut.fi>
|
6886 |
04-Mar-1995 |
nate |
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
|
1897 |
07-Aug-1994 |
wollman |
Move RPC stub generator program over from 1.1.5.
Submitted by: Original work in 1.x by J. T. Conklin.
|