1
0
mirror of https://github.com/samba-team/samba.git synced 2025-03-12 20:58:37 +03:00

149 Commits

Author SHA1 Message Date
Volker Lendecke
68c43191c8 r17315: Make talloc and tdb C++-warning-free. Would this also be interesting in talloc
and tdb "upstream"?

Volker
2007-10-10 11:38:25 -05:00
Jeremy Allison
9dafb7f48c r16945: Sync trunk -> 3.0 for 3.0.24 code. Still need
to do the upper layer directories but this is what
everyone is waiting for....

Jeremy.
2007-10-10 11:19:14 -05:00
Jeremy Allison
3cd5c3df0d r14954: Fix #3569 based on William Jojo's work. AIX also
has the linear posix locking issue which causes
CLEAR_IF_FIRST to cause performance problems.
As we know we're in a daemon architecture with
long-lived parent we can avoid this in the Samba
case. Add a comment explaining this.
Jeremy.
2007-10-10 11:15:55 -05:00
Jeremy Allison
b51edde4d6 r14030: Fix resource leak in error codepath. Coverity CID #64.
Jeremy.
2007-10-10 11:11:06 -05:00
Jeremy Allison
9ed3bd431c r13792: Merged Simo's fixes for tdbtraverse.
Jeremy.
2007-10-10 11:10:54 -05:00
Jeremy Allison
b1722b7bd1 r10355: Merge back the clear-if-first fix from Samba4. Couldn't wait tridge, sorry :-).
Jeremy.
2007-10-10 11:03:41 -05:00
Jeremy Allison
cfe5a7e5f8 r9852: Add tridge's Samba4 tdb optimisations.
Jeremy.
2007-10-10 11:03:26 -05:00
Volker Lendecke
5e6fef32b3 r9095: Add crude chainlength statistics to the crude tdbtool.
Volker
2007-10-10 11:00:25 -05:00
Jeremy Allison
9506b8e145 r7882: Looks like a large patch - but what it actually does is make Samba
safe for using our headers and linking with C++ modules. Stops us
from using C++ reserved keywords in our code.
Jeremy
2007-10-10 10:58:00 -05:00
Jeremy Allison
b438cb0a85 r7640: Fix based on work from "Shlomi Yaakobovich" <Shlomi@exanet.com> to catch
loops in corrupted tdb files.
Jeremy.
2007-10-10 10:57:18 -05:00
Gerald Carter
9727d05241 r7139: trying to reduce the number of diffs between trunk and 3.0; changing version to 3.0.20pre1 2007-10-10 10:57:02 -05:00
Herb Lewis
94e5347266 r6623: This change fixes a few broken commands plus adds some
new commands. It also restructures it so you can execute
a single command from the command line. Input strings are
parsed to allow input of arbitrary characters using the
\xx syntax for hex values.
2007-10-10 10:56:47 -05:00
Jeremy Allison
28772dfca1 r6235: Partial fix for bugid #2581. Ensure if realloc fails on an internal
tdb we fail gracefully.
Jeremy.
2007-10-10 10:56:31 -05:00
Derrell Lipman
994694f7f2 r6149: Fixes bugs #2498 and 2484.
1. using smbc_getxattr() et al, one may now request all access control
   entities in the ACL without getting all other NT attributes.
2. added the ability to exclude specified attributes from the result set
   provided by smbc_getxattr() et al, when requesting all attributes,
   all NT attributes, or all DOS attributes.
3. eliminated all compiler warnings, including when --enable-developer
   compiler flags are in use.  removed -Wcast-qual flag from list, as that
   is specifically to force warnings in the case of casting away qualifiers.

Note: In the process of eliminating compiler warnings, a few nasties were
      discovered.  In the file libads/sasl.c, PRIVATE kerberos interfaces
      are being used; and in libsmb/clikrb5.c, both PRIAVE and DEPRECATED
      kerberos interfaces are being used.  Someone who knows kerberos
      should look at these and determine if there is an alternate method
      of accomplishing the task.
2007-10-10 10:56:24 -05:00
Derrell Lipman
5b19ede88e r6127: Eliminated all compiler warnings pertaining to mismatched "qualifiers". The
whole of samba comiles warning-free with the default compiler flags.

Temporarily defined -Wall to locate other potential problems.  Found an
unused static function (#ifdefed out rather than deleted, in case it's
needed for something in progress).

There are also a number of uses of undeclared functions, mostly krb5_*.
Files with these problems need to have appropriate header files included,
but they are not fixed in this update.

oplock_linux.c.c has undefined functions capget() and capset(), which need
to have "#undef _POSIX_SOURCE" specified before including <sys/capability.h>,
but that could potentially have other side effects, so that remains uncorrected
as well.

The flag -Wall should be added permanently to CFLAGS, and all warnings then
generated should be eliminated.
2007-10-10 10:56:24 -05:00
Jeremy Allison
f997c28bb8 r5532: Patch to detect infinite loops when traversing a tdb from "Shlomi Yaakobovich" <Shlomi@exanet.com>
Jeremy.
2007-10-10 10:55:45 -05:00
Jeremy Allison
620f2e608f r4088: Get medieval on our ass about malloc.... :-). Take control of all our allocation
functions so we can funnel through some well known functions. Should help greatly with
malloc checking.
HEAD patch to follow.
Jeremy.
2007-10-10 10:53:32 -05:00
Jeremy Allison
c3e87f9fa5 r2999: Remove lockedkeys code. Not used.
Jeremy.
2007-10-10 10:52:59 -05:00
Jeremy Allison
365b203164 r2979: Fix incorrect locks/unlocks in tdb_lockkeys()/tdb_unlockkeys().
Spotted by Taj Khattra <taj.khattra@gmail.com>.
Jeremy.
2007-10-10 10:52:58 -05:00
Jim McDonough
67c737118f r2239: Fixup formatting errors in TDB_LOG calls. Add printf attribute support to
tdb log functions.
2007-10-10 10:52:37 -05:00
Jim McDonough
30da4e7771 r2131: Fixup format string. The magic value format specifier was missing, so
the logged offset was really the magic value, and the true offset was
never displayed.
2007-10-10 10:52:32 -05:00
Jeremy Allison
d7ea1ea8fb r2032: If you're selecting a hash algorithm for tdb, you need to do it at open time,
it doesn't make sense anywhere else.
Jeremy.
2007-10-10 10:52:29 -05:00
Jeremy Allison
3fbadac85b r2026: Simplify statcache to use an in-memory tdb. Modify tdb to use
a customer hash function for this tdb (yes it does make a difference
on benchmarks). Remove the no longer used hash.c code.
Jeremy.
2007-10-10 10:52:29 -05:00
Andrew Tridgell
9d1a08d65c merge tdb changes from samba4 - this means tdb is now under the LGPL, as discussed and agreed previously -
Jeremy Allison
14dee03801 Fix the "too many fcntl locks" scalability problem raised by tridge.
I've now tested this in daemon mode and also on xinetd and I'm pretty
sure it's working.
Jeremy.
-
Tim Potter
2423a45947 Don't log an error in tdb_brlock() if a non-blocking lock returns EAGAIN -
it's supposed to do that.
-
Andrew Bartlett
c9f9d6d317 In tdb_allocate(), we would create a new record by writing a local variable
'newrec' into the tdb.

This was not initialised, so valgrind warned about it.

(Note:  valgrind only makes sense on tdbs with 'mmap = no' in your smb.conf)

Andrew Bartlett
-
Tim Potter
2d03d81f75 Add some debugs in the error paths for tdb_brlock() to help track down
a locking problem on HPUX.
-
Andrew Tridgell
76992e7d16 fixed spinlocks in tdb
I still wouldn't recommend them, but at least they now work
-
Jeremy Allison
155c9ce666 Change some internal interfaces to cause the hash (which is *expensive*)
to be calculated less often. No change to external interface.
Jeremy.
-
Andrew Tridgell
f327c06108 fixed a bug found by volker
when we are traversing a readonly dababase we should not try to
cleanup the pending-delete records
-
Tim Potter
72e7290daa Comment syncup. -
Tim Potter
0eee7a4b1e Merge of tdb_unlockeys() crash fix. -
Martin Pool
7090d9f693 When opening an existing DB, don't require the hash_size specified to
the open call to be the same as that of the existing tdb.  The
specified hash_size is only used if the tdb needs to be (re)created.

With this patch in place, tdbtool can open the printing tdbs, which
are created with a hash_size of 5000.  Before it would fail with EIO.
-
Jeremy Allison
fcaacb5fab Ensure tdb error code is set for corrupt and i/o errors before calling
the log function. This allows the log function to take action.
Jeremy.
-
Jeremy Allison
b300696cb5 Ensure we overwrite a tdb if the hash size changes.
Jeremy.
-
Jeremy Allison
724cefabb0 Added tdb_append() call. Efficiently adds to an entry. Used by new messaging
code. Also added torture tests for it.
Jeremy.
-
Jeremy Allison
d4b795e6a4 Add chainlock_read functions to get a read lock. Used in *massively*
contended tdb's (and I've got one :-).
Jeremy.
-
Jeremy Allison
d030df7643 Merge of scalable printing code fix... Needs testing.
Jeremy.
-
Jeremy Allison
9fe3c0b90d Add a timeout to tdb_lock_bystring(). Ensure we never have more than
MAX_PRINT_JOBS in a queue.
Jeremy.
-
Jeremy Allison
7b841247bd Make explicit the difference between a tdb key with no data attached, and
a non existent entry. Stop a malloc(0) being called in the first case.
Jeremy.
-
Gerald Carter
65e7b5273b sync'ing up for 3.0alpha20 release -
Andrew Tridgell
03ac082dcb updated the 3.0 branch from the head branch - ready for alpha18 -
Jeremy Allison
16015c07ea Added Shirish's client side caching policy change.
Jeremy.
-
Simo Sorce
af0fa4cf7c better check of called function's return
tdbtorture say it's ok
-
Andrew Bartlett
3bf4b42771 Various comment fixes from Rafal Szczesniak <mimir@diament.ists.pwr.wroc.pl> -
Jeremy Allison
9dae1398b4 Memory leak on error condition fixed by Kian Win <codegrunt@rubbercookie.com>.
Jeremy.
-
Tim Potter
6a58c9bd06 Removed version number from file header.
Changed "SMB/Netbios" to "SMB/CIFS" in file header.
-
Tim Potter
5fb3be6291 Raise log level of warning produced when the open() of the tdb fails.
Sometimes an open error is OK.
-
Jeremy Allison
4f703b84cd Move SAFE_FREE into tdb.c to stop exporting it into tdb.h namespace.
Jeremy.
-