Age | Commit message (Collapse) | Author | Files | Lines |
|
the success case
|
|
rangesize"
|
|
autorid can only be used as a backend for the default idmap configuration.
|
|
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Mon Jun 20 13:45:21 CEST 2011 on sn-devel-104
|
|
This fixes a few Coverity errors
|
|
|
|
This is a replacement for tevent_req_nomem(NULL, req)
|
|
I don't think this kind of hack belongs in the tdb2 source, but SAMBA uses
it to speed testing, so we should respect it: handle it in our compat
open wrapper.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-User: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-Date: Mon Jun 20 12:32:08 CEST 2011 on sn-devel-104
|
|
This is simplistic. We need to support making TDB2 a standalone library,
but for now, we simply built it in-tree.
Once we have tdb1 compatibility in tdb2, we can rename this option to
--enable-tdb2.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Soon, TDB2 will handle tdb1 files, but until then, we substitute.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 doesn't have (the racy) signal pointer; the new method is to
override the locking callbacks and do the timeout internally.
The technique here is to invalidate the struct flock when the timeout
occurs, so it works even if it happens before we enter the fcntl() call.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
This is a bit messy, but it works. Kept as a separate patch so it's
easier to merge back and forth with CCAN's tdb2.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
My previous patches fixed up all direct TDB callers, but there are a
few utility functions and the db_context functions which are still
using the old -1 / 0 return codes.
It's clearer to fix up all the callers of these too, so everywhere is
consistent: non-zero means an error.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
This is a helper for the common case of opening a tdb with a logging
function, but it doesn't do all the work, since TDB1 and TDB2's log
functions are different types.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Fixup callers to tdb_parse_record() to be compatible with tdb2.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB has no idea of endian itself, but it knows whether the TDB is the
same endian as the current machine, so we should use that rather than
implementing TDB_BIGENDIAN in tdb2.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
We don't expose freelist or hash size for TDB2.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
These don't exist in tdb2. The former is used in one weird place in
tdb1, and the latter not at all.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
The typedef is TDB2 compatible, the struct isn't.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Since TDB2 functions return the error directly, tdb_errorstr() taken an
error code, not the tdb as it does in TDB1.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Note that tdb_nextkey_compat frees the old key for us.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 returns void here. tdb_unlockall will *always* return with the
database unlocked, but it will complain via the log function if it wasn't
locked.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 returns a negative error number on failure. This is compatible
if we always check for < 0 instead of == -1.
Also, there's no tdb_traverse_read in TDB2: we don't try to make
traverse reliable any more, so there are no write locks anyway.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 returns void here. tdb_chainunlock will *always* return with the
chain unlocked, but it will complain via the log function if it wasn't
locked.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 returns a negative error number on failure. This is compatible
if we always check for != 0 instead of == -1.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 returns void here. tdb_transaction_cancel will *always* return
with the transaction cancelled, but it will complain via the log
function if a transaction wasn't in progress.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 returns a negative error number on failure. This is compatible
if we always check for != 0 instead of == -1.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 returns a negative error number on failure. This is compatible
if we always check for != 0 instead of == -1.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 returns a negative error number on failure. This is compatible
if we always check for != 0 instead of == -1.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
This is a noop for tdb1.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
We change all the headers and wscript files to use tdb_compat; this
means we have one place to decide whether to use TDB1 or TDB2.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2's API is slightly different from TDB1. In particular, all functions
return 0 (TDB_SUCCESS) or a negative error number, rather than -1 or tdb_null
and storing the error in tdb_error() (though TDB2 does that as well).
The simplest fix is to replace all the different functions with a wrapper,
and that is done here.
Compatibility functions:
tdb_null: not used as an error return, so not defined by tdb2.
tdb_fetch_compat: TDB1-style data-returning tdb_fetch.
tdb_firstkey_compat: TDB1-style data-returning tdb_firstkey
tdb_nextkey_compat: TDB1-style data-returning tdb_nextkey, with
TDB2-style free of old key.
tdb_errorstr_compat: TDB1-style tdb_errorstr() which takes TDB instead of ecode.
TDB_CONTEXT: TDB1-style typedef for struct tdb_context.
tdb_open_compat: Simplified open routine which takes log function, sets
TDB_ALLOW_NESTING as Samba expects, and adds TDB_CLEAR_IF_FIRST support.
Things defined away in TDB2 wrappers:
tdb_traverse_read: TDB2's tdb_traverse only uses read-locks anyway.
tdb_reopen/tdb_reopen_all: TDB2 detects this error itself.
TDB_INCOMPATIBLE_HASH: TDB2 uses the Jenkins hash already.
TDB_VOLATILE: TDB2 shouldn't have freelist scaling issues.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Rather than tdb's internal one.
|
|
Rather than tdb's internal one.
|
|
It's a nice hash, but this usage has nothing to do with TDB. So use the
Jenkins hash directly from CCAN instead (it's the same one).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Imported from git://git.ozlabs.org/~ccan/ccan init-1161-g661d41f
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Mon Jun 20 11:17:47 CEST 2011 on sn-devel-104
|
|
Autobuild-User: Matthieu Patou <mat@samba.org>
Autobuild-Date: Mon Jun 20 09:23:15 CEST 2011 on sn-devel-104
|
|
The two error tables need to be combined, but for now seperate the names.
(As the common parts of the tree now use the _common function,
errmap_unix.c must be included in the s3 autoconf build).
Andrew Bartlett
Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Mon Jun 20 08:12:03 CEST 2011 on sn-devel-104
|
|
Due to library link orders, this is already the function that is being
used. However we still need to sort out the duplicate symbol issues,
probably by renaming things.
Andrew Bartlett
|
|
The functions which uesed these tables have since moved in common.
Andrew Bartlett
|
|
On default installs, this will be the same as the old lock_path(), but
lock_path() is now a directory that can safely be mapped to /var/locks
and removed by the OS on reboot. It is important that the directory
permissions of this directory be preserved, as they may be customised.
Andrew Bartlett
|
|
This does not move statedir, leaving it in PREFIX/var/locks because
state files such as idmap are dangerous to move, as they might
re-create, causing chaos.
This isn't ideal, but I don't have a better solution right now.
Andrew Bartlett
|
|
The following changes are made since Samba 3.6:
* --with-ncalrpcdir and --with-nmbdsocketdir are replaced with --with-socket-dir
(with ntp_signd, winbindd, nmbd subdirs)
* This moves the winbind socket out of /tmp. Distributions have moved
this out of /tmp for quite some time now, and /var/run in the FHS
blessed location these days. --with-socketdir should point to
/var/run in a distribution package.
* Configuration files are expected in PREFIX/etc instead of PREFIX/lib
(they need to be moved manually)
* SWAT data files have moved to PREFIX/share/swat (alongside
PREFIX/share/setup containing samba4 provision templates).
* The --with-fhs option is no longer available (it was never very
useful, and major distributions (Debian, OpenSuSE, Fedora) either
specified every option (overriding the effect) or didn't specify it
at all.
* PID files are now in PREFIX/var/run, moved from PREFIX/var/locks
* The ncalrpc and nmbd sockets are now in PREFIX/var/run by default
The following changes are made for users of Samba3 binaries built with the top level build in master
* 'state' files are now expected to be in their Samba 3.6 location
PREFIX/var/locks (and will need to be moved manually)
Andrew Bartlett
Signed-off-by: Andrew Tridgell <tridge@samba.org>
|
|
present
Autobuild-User: Matthieu Patou <mat@samba.org>
Autobuild-Date: Mon Jun 20 00:30:59 CEST 2011 on sn-devel-104
|
|
information
|
|
|
|
|