| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Fixes: 3a686b851f8f
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
POSIX.1 states that `dbm_nextkey` must return an invalid key
(i.e., `key.dptr == NULL`) after the end of the database was reached.
The current implementation of `hash_seq` will incorrectly restart
the key sequence after the end of the database is reached.
Fix this by checking the "current bucket" index when R_NEXT is passed.
Sponsored by: Klara, Inc.
Differential Revision: https://reviews.freebsd.org/D51635
Reviewed by: markj
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The dbm(3) manpage explicitly states that O_WRONLY is not allowed in
dbm_open, but a more recent comment in ` __hash_open` suggests otherwise.
Furthermore, POSIX.1 allows O_WRONLY in dbm_open and states
that the underlying file must be opened for both reading and writing.
Fix this by correcting the O_WRONLY check and moving it further into
the function to make sure that the original flags are stored in hashp.
Sponsored by: Klara, Inc.
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D51514
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
dbm_open currently returns an error when opening a missing database
with O_CREAT but creates the request database file. This is caused
by a buggy check in __hash_open which attempts to detect a new
(or empty) database file, but fails to take the O_CREAT flag into
account.
Fix this by expanding the check to include O_CREAT.
Fixes: edcdc752ecdd
Sponsored by: Klara, Inc.
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D51491
|
|
|
|
|
|
|
| |
This is a residual of the $FreeBSD$ removal.
MFC After: 3 days (though I'll just run the command on the branches)
Sponsored by: Netflix
|
|
|
|
|
|
|
| |
This requires that mpool.c be compiled with -DSTATISTICS and we provide
no mechanism to do this.
Differential Revision: https://reviews.freebsd.org/D44185
|
|
|
|
|
|
|
|
| |
From "contigous" to "contiguous".
Signed-off-by: rilysh <nightquick@proton.me>
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/1119
|
|
|
|
|
|
|
|
| |
From "unitialized" to "uninitialized".
Signed-off-by: rilysh <nightquick@proton.me>
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/1119
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Apply the following automated changes to try to eliminate
no-longer-needed sys/cdefs.h includes as well as now-empty
blank lines in a row.
Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/
Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/
Remove /\n+#if.*\n#endif.*\n+/
Remove /^#if.*\n#endif.*\n/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/
Sponsored by: Netflix
|
|
|
|
|
|
|
|
|
|
|
| |
We've ifdef'd out the copyright strings for some time now. Go ahead and
remove the ifdefs. Plus whatever other detritis was left over from other
recent removals. These copyright strings are present in the comments and
are largely from CSRG's attempt at adding their copyright to every
binary file (which modern interpretations of the license doesn't
require).
Sponsored by: Netflix
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
| |
These were left over from $FreeBSD$ removal.
Reviewed by: emaste
Differential Revision: https://reviews.freebsd.org/D42612
|
|
|
|
|
|
|
|
|
| |
These sys/cdefs.h are not needed. Purge them. They are mostly left-over
from the $FreeBSD$ removal. A few in libc are still required for macros
that cdefs.h defines. Keep those.
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D42385
|
|
|
|
| |
Differential Revision: https://reviews.freebsd.org/D42192
|
|
|
|
| |
Remove /^%\s*RCSID:\s*\$FreeBSD\$.*$\n/
|
|
|
|
| |
Remove /^\.\\"\s*\$FreeBSD\$$\n/
|
|
|
|
| |
Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/
|
|
|
|
| |
Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
|
|
|
|
| |
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
|
|
|
| |
Remove /^\s*\*+\s*\$FreeBSD\$.*$\n/
|
|
|
|
|
|
| |
Remove non-standard $FreeBSD$ comment. It's not useful
Sponsored by: Netflix
|
|
|
|
|
|
|
|
|
| |
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch
up to that fact and revert to their recommended match of BSD-2-Clause.
Discussed with: pfg
MFC After: 3 days
Sponsored by: Netflix
|
|
|
|
|
|
|
| |
No functional change intended.
Reviewed by: mjg, imp, kib
Differential Revision: https://reviews.freebsd.org/D39278
|
|
|
|
|
|
|
|
|
|
| |
There are some sections which could be improved
and work to do so is on going. The work will be
covered via 'X-MFC-WITH' commits.
Obtained from: OpenBSD
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D34759
|
|
|
|
|
|
|
|
|
|
|
| |
This is needed to bootstrap llvm-tblgen on Linux since LLVM calls
`::open(...)` which does not work if open is a statement macro.
Also stop defining O_SHLOCK/O_EXLOCK and update the only bootstrap tools
user of those flags to deal with missing definitions.
Reviewed By: jrtc27
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D31226
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This option was added as a transition aide when symbol versioning was
first added. It was enabled by default in 2007 and is supported even
by the old GPLv2 binutils. Trying to disable it currently fails to
build in libc and at this point it isn't worth fixing the build.
Reported by: Michael Dexter
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D24637
Notes:
svn path=/head/; revision=360511
|
|
|
|
|
|
|
|
|
| |
See r333391 for the rationale.
MFC after: 1 week
Notes:
svn path=/head/; revision=333449
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Mainly focus on files that use BSD 2-Clause license, however the tool I
was using mis-identified many licenses so this was mostly a manual - error
prone - task.
The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.
Notes:
svn path=/head/; revision=326193
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Mainly focus on files that use BSD 3-Clause license.
The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.
Special thanks to Wind River for providing access to "The Duke of
Highlander" tool: an older (2014) run over FreeBSD tree was useful as a
starting point.
Notes:
svn path=/head/; revision=326025
|
|
|
|
|
|
|
|
|
|
|
|
| |
Renumber cluase 4 to 3, per what everybody else did when BSD granted
them permission to remove clause 3. My insistance on keeping the same
numbering for legal reasons is too pedantic, so give up on that point.
Submitted by: Jan Schaumann <jschauma@stevens.edu>
Pull Request: https://github.com/freebsd/freebsd/pull/96
Notes:
svn path=/head/; revision=314436
|
|
|
|
|
|
|
|
|
|
| |
When writing out pages in the "other endian" format, make a copy
instead of trashing the in-memory one.
Obtained from: NetBSD (CVS rev. 1.29)
Notes:
svn path=/head/; revision=306349
|
|
|
|
|
|
|
|
|
| |
Obtained from: NetBSD (from krb5 tree)
MFC after: 3 weeks
Notes:
svn path=/head/; revision=306332
|
|
|
|
|
|
|
|
|
|
|
| |
The last argument of dbm_open() should be a mode_t according to POSIX;
not an int.
Reviewed by: pfg, kib
Differential Revision: https://reviews.freebsd.org/D6650
Notes:
svn path=/head/; revision=301066
|
|
|
|
|
|
|
|
|
|
|
|
| |
According to POSIX, it should use void *, not char *. Unfortunately, the
dsize field also has the wrong type. It should be size_t. I'm not going
to change that, as that will break the ABI.
Reviewed by: pfg
Differential Revision: https://reviews.freebsd.org/D6647
Notes:
svn path=/head/; revision=300999
|
|
|
|
|
|
|
|
| |
We have a howmany() macro in the <sys/param.h> header that is
convenient to re-use as it makes things easier to read.
Notes:
svn path=/head/; revision=298600
|
|
|
|
|
|
|
|
| |
rounddown2 tends to produce longer lines than the original code but
still it makes the code more readable.
Notes:
svn path=/head/; revision=298323
|
|
|
|
|
|
|
|
|
| |
According to style(9):
> normally, include <sys/types.h> OR <sys/param.h>, but not both.
(<sys/param.h> already includes <sys/types.h> when LOCORE is not defined).
Notes:
svn path=/head/; revision=298226
|
|
|
|
|
|
|
|
|
|
|
|
| |
While here also cleanup some surrounding code; particularly
drop some malloc() casts.
Found with devel/coccinelle.
Reviewed by: bde (previous version - all new bugs are mine)
Notes:
svn path=/head/; revision=297790
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes a major performance regression when reading db files such as
the pw database during a 'pkg install'.
MFC after: 1 week
Tested by: bapt
Reviewed by: bapt
Sponsored by: EMC / Isilon Storage Division
Differential Revision: https://reviews.freebsd.org/D5868
Notes:
svn path=/head/; revision=297626
|
|
|
|
|
|
|
|
|
|
| |
WITHOUT_SYMVER necessarily implies building a system without symver
backwards compatability.
Sponsored by: The FreeBSD Foundation
Notes:
svn path=/head/; revision=296915
|
|
|
|
|
|
|
|
|
|
|
|
| |
There is also a small portability crutch, also present in NetBSD,
to allow compiling on a system that doesn't define O_CLOEXEC.
Approved by: rpaulo (mentor)
Obtained from: NetBSD (r1.17, r1.18)
Differential Revision: https://reviews.freebsd.org/D5549
Notes:
svn path=/head/; revision=296423
|
|
|
|
|
|
|
|
|
| |
While here also drop a malloc cast.
Obtained from: NetBSD (CVS Rev. 1.18 - 1.20)
Notes:
svn path=/head/; revision=295975
|
|
|
|
|
|
|
| |
Obtained from: NetBSD (CVS Rev. 1.20)
Notes:
svn path=/head/; revision=295973
|
|
|
|
|
|
|
|
|
|
|
|
| |
make sure the changes are on disk. The people at pfSense noticed that
it didn't always make it to the disk soon enough with soft updates.
Differential Revision: https://reviews.freebsd.org/D5186
Reviewed by: garga, vangyzen, bapt, se
MFC after: 1 week
Notes:
svn path=/head/; revision=295924
|
|
|
|
|
|
|
|
|
|
| |
pointers.
Obtained from: CheriBSD (e3a69027cc5a384431156d61c90d4304387a9b9d)
Sponsored by: DARPA, AFRL
Notes:
svn path=/head/; revision=295031
|
|
|
|
| |
Notes:
svn path=/head/; revision=288042
|
|
|
|
| |
Notes:
svn path=/head/; revision=287761
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
are aliases for the syscall stubs and are plt-interposed, to the
libc-private aliases of internally interposed sigprocmask() etc.
Since e.g. _sigaction is not interposed by libthr, calling signal()
removes thr_sighandler() from the handler slot etc. The result was
breaking signal semantic and rtld locking.
The added __libc_sigprocmask and other symbols are hidden, they are
not exported and cannot be called through PLT. The setjmp/longjmp
functions for x86 were changed to use direct calls, and since
PIC_PROLOGUE only needed for functional PLT indirection on i386, it is
removed as well.
The PowerPC bug of calling the syscall directly in the setjmp/longjmp
implementation is kept as is.
Reported by: Pete French <petefrench@ingresso.co.uk>
Tested by: Michiel Boland <boland37@xs4all.nl>
Reviewed by: jilles (previous version)
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Notes:
svn path=/head/; revision=287292
|
|
|
|
|
|
|
|
| |
Reported by: Clang static analyzer
Obtained from: NetBSD
Notes:
svn path=/head/; revision=283068
|