History log of /freebsd-10.1-release/lib/libc/db/btree/
Revision Date Author Comments
272461 03-Oct-2014 gjb

Copy stable/10@r272459 to releng/10.1 as part of
the 10.1-RELEASE process.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


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


254289 13-Aug-2013 jilles

db: Use O_CLOEXEC instead of separate fcntl() call.


223262 18-Jun-2011 benl

Fix clang warnings.

Approved by: philip (mentor)


194804 24-Jun-2009 delphij

Update SCCS IDs for Berkeley DB 1.86 merge.


194803 24-Jun-2009 delphij

style: operators should appear at the line end if we have to wrap.


190498 28-Mar-2009 delphij

Minor changes from Berkeley DB 1.86 and further improvements from OpenBSD.
This does not include the new hash routines since they will cause problems
when reading old hash files.

Since mpool(3) has been changed, provide a compatibility shim for older
binaries.

Obtained from: OpenBSD


190485 28-Mar-2009 delphij

db/btree/bt_open.c: check return value of snprintf() and return value
if the result is truncated.

db/hash/hash_page.c: use the same way to create temporary file as
bt_open.c; check snprintf() return value.

Obtained from: OpenBSD


190484 28-Mar-2009 delphij

Several signed/unsigned warning fixes.


190482 28-Mar-2009 delphij

When allocating memory, zero out them if we don't intend to overwrite them
all; before freeing memory, zero out them before we release it as free
heap. This will eliminate some potential information leak issue.

While there, remove the PURIFY option. There is a slight difference between
the new behavior and the old -DPURIFY behavior, with the latter initializes
memory with 0xff's. The difference between old and new approach does not
generate observable difference.

Obtained from: OpenBSD (partly).


190344 23-Mar-2009 delphij

Save errno before calling _close(), which may clear it.

Obtained from: OpenBSD


190342 23-Mar-2009 delphij

use more proper format string.

Obtained from: NetBSD via OpenBSD


189387 05-Mar-2009 delphij

Our realloc(3) and reallocf(3) can handle NULL, which turns it into a
malloc(3) call, so don't test if a pointer is NULL.

Obtained from: OpenBSD (in spirit)


189327 04-Mar-2009 delphij

Style changes (including additional casts to shut up warnings). This
commit does not affect MD5 of object file.


189292 03-Mar-2009 delphij

Rename variable 'index' to 'idx' to avoid name collision with index(3),
this commit does not affect any object code.

Obtained from: OpenBSD
Verified with: md5(1)


189291 02-Mar-2009 delphij

Diff reduction against OpenBSD: ANSI'fy prototypes.

(This is part of a larger changeset which is intended to reduce diff only,
thus some prototypes were left intact since they will be changed in the
future).

Verified with: md5(1)


165903 09-Jan-2007 imp

Per Regents of the University of Calfornia letter, remove advertising
clause.

# If I've done so improperly on a file, please let me know.


135178 13-Sep-2004 kuriyama

Fix a condition where the hole would be inserted in the wrong
place during a split.

Obtained from: NetBSD


135038 10-Sep-2004 kuriyama

I found "portsdb -u" dumps core with recent INDEX file, and this is
caused by refering broken (uninitialized?) pointer which is retrieved
from __bt_new() (and from mpool_new()).

I don't know why this linp[0] is read before stored because this
should be controlled by .lower and .upper member of PAGE structure
which are correctly initialized.

But this workaround fixes the problem on my environment and this
module has #ifdef PURIFY option which initializes new and reused
memory from mpool by memset(p, 0xff, size) like as I did.

Please feel free to fix the real bug instead of my workaround.


135024 10-Sep-2004 kuriyama

Fix format strings to unbreak with -DDEBUG option.


115411 30-May-2003 tmm

Fix a sizeof error in __bt_put: when writing they key and data sizes
to a buffer in the big key/data case, memmove() was used on pointers
to size_ts, but only sizeof(u_int32_t) bytes where copied. This broke
on big_endian architectures where sizeof(size_t) > sizeof(u_int32_t).

This bug broke portupgrade (by way of ruby_bdb1) on sparc64.

Approved by: re (rwatson)


111010 16-Feb-2003 nectar

Eliminate 61 warnings emitted at WARNS=2 (leaving 53 to go).
Only warnings that could be fixed without changing the generated object
code and without restructuring the source code have been handled.

Reviewed by: /sbin/md5


108533 01-Jan-2003 schweikh

Correct typos, mostly s/ a / an / where appropriate. Some whitespace cleanup,
especially in troff files.


107052 18-Nov-2002 ru

libc_r wasn't so tied to libc for 22 months.


93039 23-Mar-2002 obrien

W/o __P, the internal declarations will all fit on one line.


92991 22-Mar-2002 obrien

Fix the style of the SCM ID's.
I believe have made all of libc .h's as consistent as possible.


92986 22-Mar-2002 obrien

Fix the style of the SCM ID's.
I believe have made all of libc .c's as consistent as possible.


92941 22-Mar-2002 obrien

Remove multi-line __P() usage.


92905 21-Mar-2002 obrien

Remove __P() usage.


92889 21-Mar-2002 obrien

Remove 'register' keyword.


71579 24-Jan-2001 deischen

Remove _THREAD_SAFE and make libc thread-safe by default by
adding (weak definitions to) stubs for some of the pthread
functions. If the threads library is linked in, the real
pthread functions will pulled in.

Use the following convention for system calls wrapped by the
threads library:
__sys_foo - actual system call
_foo - weak definition to __sys_foo
foo - weak definition to __sys_foo

Change all libc uses of system calls wrapped by the threads
library from foo to _foo. In order to define the prototypes
for _foo(), we introduce namespace.h and un-namespace.h
(suggested by bde). All files that need to reference these
system calls, should include namespace.h before any standard
includes, then include un-namespace.h after the standard
includes and before any local includes. <db.h> is an exception
and shouldn't be included in between namespace.h and
un-namespace.h namespace.h will define foo to _foo, and
un-namespace.h will undefine foo.

Try to eliminate some of the recursive calls to MT-safe
functions in libc/stdio in preparation for adding a mutex
to FILE. We have recursive mutexes, but would like to avoid
using them if possible.

Remove uneeded includes of <errno.h> from a few files.

Add $FreeBSD$ to a few files in order to pass commitprep.

Approved by: -arch


68234 02-Nov-2000 kris

More secure temporary filename. This needs to be revisited to use
mkstemp().


56698 27-Jan-2000 jasone

Simplify sytem call renaming. Instead of _foo() <-- _libc_foo <-- foo(),
just use _foo() <-- foo(). In the case of a libpthread that doesn't do
call conversion (such as linuxthreads and our upcoming libpthread), this
is adequate. In the case of libc_r, we still need three names, which are
now _thread_sys_foo() <-- _foo() <-- foo().

Convert all internal libc usage of: aio_suspend(), close(), fsync(), msync(),
nanosleep(), open(), fcntl(), read(), and write() to _foo() instead of foo().

Remove all internal libc usage of: creat(), pause(), sleep(), system(),
tcdrain(), wait(), and waitpid().

Make thread cancellation fully POSIX-compliant.

Suggested by: deischen


55837 12-Jan-2000 jasone

Add three-tier symbol naming in support of POSIX thread cancellation
points. For library functions, the pattern is __sleep() <--
_libc_sleep() <-- sleep(). The arrows represent weak aliases. For
system calls, the pattern is _read() <-- _libc_read() <-- read().


50476 28-Aug-1999 peter

$Id$ -> $FreeBSD$


39327 16-Sep-1998 imp

Replace memory leaking instances of realloc with non-leaking reallocf.
In some cases replace if (a == null) a = malloc(x); else a =
realloc(a, x); with simple reallocf(a, x). Per ANSI-C, this is
guaranteed to be the same thing.

I've been running these on my system here w/o ill effects for some
time. However, the CTM-express is at part 6 of 34 for the CAM
changes, so I've not been able to do a build world with the CAM in the
tree with these changes. Shouldn't impact anything, but...


39058 11-Sep-1998 imp

Don't trust TMPDIR if we're setuid root. This is used only for the
backing file for an anonymous (memory based) btree, and I don't think
that any setuid programs actually use it, but it is better to be safe
than sorry. This has been in my tree for a long time, maybe a year or
more...

Inspired by: Similar changes in OpenBSD, if memory serves (like nearly
a year ago)


37155 25-Jun-1998 guido

Fix btree problems. This passes regressions tests.
PR: 7009
Obtained from: http://www.sleepycat.com/update/patch.185.html, patches 1.2,
1.3 and 1.4


29574 18-Sep-1997 phk

Many places in the code NULL is used in integer context, where
plain 0 should be used. This happens to work because we #define
NULL to 0, but is stylistically wrong and can cause problems
for people trying to port bits of code to other environments.

PR: 2752
Submitted by: Arne Henrik Juul <arnej@imf.unit.no>


25401 03-May-1997 jb

Changed all paths to be relative to src/lib instead of src/lib/libc
so that all these makefiles can be used to build libc_r too.

Added .if ${LIB} == "c" tests to restrict man page builds to libc
to avoid needlessly building them with libc_r too.

Split libc Makefile into Makefile and Makefile.inc to allow the
libc_r Makefile to include Makefile.inc too.


17141 12-Jul-1996 jkh

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


14287 27-Feb-1996 pst

Fix conflicts and merge into mainline


14273 27-Feb-1996 pst

This commit was generated by cvs2svn to compensate for changes in r14272,
which included commits to RCS files with non-trunk default branches.


8870 30-May-1995 rgrimes

Remove trailing whitespace.


1574 27-May-1994 rgrimes

This commit was generated by cvs2svn to compensate for changes in r1573,
which included commits to RCS files with non-trunk default branches.