Commit Graph

41 Commits

Author SHA1 Message Date
mycroft
b7e6351cc4 hash already uses FD_CLOEXEC -- pay attention to the return value and make it
a hard failure.

Also make btree and recno uses FD_CLOEXEC.
2005-01-19 00:23:44 +00:00
jmc
b2f782612f Completely rework how tools/compat is done. Purge all uses/references to
_NETBSD_SOURCE as this makes cross building from older/newer versions of
NetBSD harder, not easier (and also makes the resulting tools 'different')

Wrap all required code with the inclusion of nbtool_config.h, attempt to
only use POSIX code in all places (or when reasonable test w. configure and
provide definitions: ala u_int, etc).

Reviewed by lukem. Tested on FreeBSD 4.9, Redhat Linux ES3, NetBSD 1.6.2 x86
NetBSD current (x86 and amd64) and Solaris 9.

Fixes PR's: PR#17762 PR#25944
2004-06-20 22:20:14 +00:00
martin
9f96807631 When storing data size as 32bit int in an overflow page, copy the
length to a temporary u_int32_t variable and memmove from there to the
final destination - instead of copying the first four 0 bytes from a
64bit variable directly on big endian 64 bit platforms.

This makes sparc64 pass regress/lib/libc/db.
2003-12-30 21:20:16 +00:00
lukem
171d653219 Overhaul how `build.sh tools' are used:
*	Rename "config.h" to "nbtool_config.h" and
	HAVE_CONFIG_H to HAVE_NBTOOL_CONFIG_H.
	This makes in more obvious in the source when we're using
	tools/compat/config.h versus "standard autoconf" config.h

    *	Consistently move the inclusion of nbtool_config.h to before
    	<sys/cdefs.h> so that the former can provide __RCSID() (et al),
    	and there's no need to protect those macros any more.

These changes should make it easier to "tool-ify" a program by adding:
	#if HAVE_NBTOOL_CONFIG_H
	#include "nbtool_config.h"
	#endif
to the top of the source files (for the general case).
2003-10-27 00:12:41 +00:00
agc
eb7c1594f1 Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22280, verified by myself.
2003-08-07 16:42:00 +00:00
simonb
d7b879c6ec Grrr. So much for my ability to use grep(1) effectively. Pointed out
by Stephen Degler in private mail.
2003-01-20 07:12:12 +00:00
simonb
276fd1665c The Double-Semi-Colon Police. 2003-01-20 05:29:53 +00:00
thorpej
20b98814a9 Fix signed/unsigned comparison warnings. 2002-11-11 01:12:04 +00:00
groo
b8dcd239d9 Do not respect TMPDIR when s[ug]id.
from xs@kittenz.org
2002-04-16 19:00:45 +00:00
thorpej
0f3aee340f Don't pull in <sys/param.h> if we don't have to. 2002-01-22 20:41:21 +00:00
tv
c08a2cb7c2 Add hooks for reachover builds from src/tools/compat. 2002-01-21 21:33:42 +00:00
aymeric
51411b7d2b fix printf(3) warnings when defined(DEBUG) 2002-01-12 11:27:16 +00:00
aymeric
238cdd6720 add missing prototype when defined(DEBUG) 2002-01-12 11:24:48 +00:00
thorpej
585dfd612c Rename the local variable "index" to "idx" to avoid shadowing a global
declaration.
2001-12-30 19:20:40 +00:00
thorpej
42a6d41394 __bt_search(): Rename the local variable "index" to "idx" to avoid
shadowing a global declaration.
2001-12-30 19:18:23 +00:00
christos
f0c45fdbc9 protect against multiple inclusions. 2000-12-20 20:54:01 +00:00
mycroft
8102096d08 Delint. 2000-01-23 00:49:41 +00:00
mycroft
3bf07e90f3 Fix a condition where the hole would be inserted in the wrong place during a
split.
1999-07-29 04:07:27 +00:00
christos
d4639c815b Adding missing braces that gcc-2.8.1 likes. 1999-03-16 18:17:56 +00:00
christos
61238e7179 delint 1998-12-09 12:42:46 +00:00
christos
d826507120 s/LALIGN/BTLALIGN 1998-11-06 19:42:43 +00:00
thorpej
e79648d085 Add some braces to make egcs happy. 1998-08-18 23:50:08 +00:00
kleink
23a9b2c5c9 Change the file mode argument to dbopen() and the db backends from int to
mode_t.
1998-05-07 19:24:20 +00:00
fair
5f06216718 /tmp to _PATH_TMP from paths.h 1998-04-07 10:40:21 +00:00
is
8871c98bb7 Bug fixes from Sleepycat Software for db_btree databases; for some corner
cases in splitting pages, and for correctly updating data base metadata.
1997-10-10 21:08:53 +00:00
jtc
43fa6fe319 If port provides __weak_alias(), provide an Standard C and POSIX pure
identifier namespace by renaming non standard functions and variables
such that they have a leading underscore.  The library will use those
names internally.  Weak aliases are used to provide the original names
to the API.

This is only the first part of this change.  It is most of the functions
which are implemented in C for all NetBSD ports.  Subsequent changes are
to add the same support to the remaining C files, to assembly files, and
to the automagically generated assembly source used for system calls.
When all of the above is done, ports with weak alias support should add
a definition for __weak_alias to <sys/cdefs.h>.
1997-07-21 14:06:24 +00:00
christos
00ae392d92 Fix RCSID's
Fix gcc warnings.
1997-07-13 18:51:48 +00:00
pk
58efb9d20c NULL => 0 (Arne Juul; PR#3629) 1997-05-17 19:24:44 +00:00
cgd
24420c0109 merge DB 1.85 changes 1996-05-03 21:50:36 +00:00
mycroft
4c34be6b52 Clean up deleted files. 1995-03-01 00:00:00 +00:00
cgd
a954b0787c add unintrusive Ids 1995-02-27 13:19:23 +00:00
cgd
a6d14e368c clean up import 1994-08-18 00:38:04 +00:00
cgd
f7b4cb000f update to 1.73 from UCB. I didn't even notice this was out! 1994-01-24 03:59:39 +00:00
cgd
65aeeefb0a version 1.71 of new db code 1993-09-17 01:06:18 +00:00
cgd
45e27c8018 upgrade new DB code to version 1.7 1993-09-09 02:41:04 +00:00
jtc
9c20f740a3 Declare rcsid strings so they are stored in text segment. 1993-08-26 00:43:03 +00:00
mycroft
e9d867ef50 Add RCS identifiers. 1993-08-01 17:54:45 +00:00
mycroft
cda4f8f6ee Add RCS identifiers. 1993-08-01 05:37:30 +00:00
cgd
9f0aa214be update db code to v1.6 from vangogh, and put it in "db" rather than "DB" 1993-06-14 23:52:39 +00:00
mycroft
6609149bb3 Clean up deleted files. 1993-06-14 21:16:14 +00:00
cgd
61f282557f initial import of 386bsd-0.1 sources 1993-03-21 09:45:37 +00:00