Age | Commit message (Collapse) | Author | Files | Lines |
|
We should do this at startup in cli_state_create()
and later calculate the negotiated capabilities in
cli_negprot_done().
metze
|
|
This is only used cli->protocol < PROTOCOL_NT1, in which case
cli_negprot_done() has already reset cli->capabilities.
metze
|
|
cli_negprot_done()
If the server doesn't support PROTOCOL_NT1 we should reset the negotiated
capabilities to 0.
metze
|
|
Signed-off-by: Jeremy Allison <jra@samba.org>
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Thu Sep 15 02:56:36 CEST 2011 on sn-devel-104
|
|
If you're going to move winbindd_cache.tdb to the state_path, do it *everywhere*.
Found by Ira Cooper <ira@wakeful.net>.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Thu Sep 15 00:43:04 CEST 2011 on sn-devel-104
|
|
s3:libsmb: remove unused cli->is_samba
metze
Signed-off-by: Jeremy Allison <jra@samba.org>
|
|
s3:libsmb: align chunk_size for cli_pull/push() to a page size of 1024 bytes
metze
Signed-off-by: Jeremy Allison <jra@samba.org>
|
|
s3:client.h: remove unused defines
metze
Signed-off-by: Jeremy Allison <jra@samba.org>
|
|
s3:libsmb: let cli_write_max_bufsize() return the max number of possible bytes
We now return what's possible on the wire.
Which is 0x1FFFF - data_offset if CAP_LARGE_WRITEX is given by
the server (without signing) or 0xFFFFFF - data_offset
if CIFS_UNIX_LARGE_READ_CAP is available (without signing/sealing).
Otherwise we return max_xmit - data_offset.
metze
Signed-off-by: Jeremy Allison <jra@samba.org>
|
|
s3:libsmb: let cli_read_max_bufsize() return the max number of possible bytes
We now return what's possible on the wire.
Which is 0xFFFF if CAP_LARGE_READX is given by the server
or 0xFFFFFF - data_offset if CIFS_UNIX_LARGE_READ_CAP
is available (without signing/sealing). Otherwise we return
max_xmit - data_offset.
metze
Signed-off-by: Jeremy Allison <jra@samba.org>
|
|
Windows 2008 R2 (and others) ignore the high bits for the read size.
Unless we're using the unix extentions and the client
uses CIFS_UNIX_LARGE_READ_CAP, we should also ignore
the high bits.
But we still need to support old "smbclient" binaries
and have to check if the client is "Samba".
metze
Signed-off-by: Jeremy Allison <jra@samba.org>
|
|
metze
Signed-off-by: Jeremy Allison <jra@samba.org>
|
|
legacy dialects
Ensure we have valid pointers.
|
|
metze
Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Wed Sep 14 19:49:24 CEST 2011 on sn-devel-104
|
|
We should return the same in all places.
metze
|
|
We should return the same in all places.
metze
|
|
We should return the same in all places.
metze
|
|
We should return the same in all places.
metze
|
|
We should return the same in all places.
metze
|
|
We should return the same in all places.
metze
|
|
We should return the same in all places
and don't mix NT_STATUS_INVALID_CONNECTION and NT_STATUS_CONNECTION_INVALID.
metze
|
|
NT_STATUS_CONNECTION_INVALID
We should return the same in all places.
metze
|
|
Doing this after the session setup is pointless,
as that's the only place where we tell the server we support
level II oplocks.
metze
Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Wed Sep 14 17:23:46 CEST 2011 on sn-devel-104
|
|
metze
|
|
Guenther
Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Wed Sep 14 15:52:10 CEST 2011 on sn-devel-104
|
|
metze
Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Wed Sep 14 09:41:02 CEST 2011 on sn-devel-104
|
|
metze
|
|
We don't make use of it yet, but it will follow.
metze
|
|
reply
This matches what windows is doing.
metze
|
|
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-User: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-Date: Wed Sep 14 06:06:41 CEST 2011 on sn-devel-104
|
|
regression intro'd in 3.2
Add "allow insecure widelinks" to re-enable the ability (requested
by some sites) to have "widelinks = yes" and "unix extensions = yes".
Based on an original patch by Linda Walsh <samba@tlinx.org>
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Wed Sep 14 03:55:45 CEST 2011 on sn-devel-104
|
|
This makes it match tdb1, which mean it will Just Work as TDB2 gets
tdb1 format support.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-User: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-Date: Wed Sep 14 02:21:29 CEST 2011 on sn-devel-104
|
|
This matters with the clear-if-first support: we need to re-establish
those locks at this point.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Keeps the tdb2 API change (which returns error codes, rather than -1)
localized. The function returns -1 down the other path, so make it
consistent.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
TDB2 versions of tdb_parse_record etc return an error code, not -1.
Turn those into -1/0 in dbwrap_tdb to insulate the rest of the code
from that change.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
Since enums and ints are compatible in C, the compiler didn't warn
that our prototypes for these functions disagreed with the
definitions.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit 6d3832ee613adeb9ae7ed6454996ffa39c32650f)
|
|
tdb_close() does genuinely return non-zero, not an error code, even in tdb2.
And tdb_exists() returns true or false, not an error code.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
This clarifies the code a little, but also provides a more explicit
mechanism which can be used to debug error handling (by introducing
tdb_err_t and making it a pointer type).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit afa6d57b7d93fe4675a952f556eb462951baa257)
|
|
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit feb36b14278b4230af70dab90369a345b6a027ef)
|
|
Lazy cut & paste of tdb names causes failure when we run in parallel.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit 380372e733416c2b348d5307f536d0a0807e95df)
|
|
tdb_repack() returns an enum TDB_ERROR, whereas
tdb1_transaction_commit is expected to return 0 or -1.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit b679512e4260b9847e2f846b07443e6907d8276f)
|
|
A left-over -1 return; should be returning ecode (probably TDB_ERR_IO).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit 077bdae6877d26749987b26a1b5b28cdba5ebbdd)
|
|
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit 9cbae0f976118472f0065eee674eacf6ab4b80c5)
|
|
These two tdb1-specific tests have been superceded by the TDB_VERSION1
flags used in the main tests.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit e42097b73f6cd509aa17a48487a707401a2d4bd0)
|
|
Don't run tdb_check with failtest on, since it is very slow. Do the
tdb_check w/ failtest in a new test, but skip MMAP suppression which
doesn't add much and slows down valgrind a lot.
Before this change run-01-new_database took 40 seconds (under
valgrind), after it takes 8 seconds, and run-12-check takes 3
seconds).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit b3ae89992ecaffed31dcc2e912539c289478801a)
|
|
The time to run tests under valgrind has become excessive; particularly
the failure tests which fork(). Thus we cut down testing:
1) api-94-repack: reduce from 234 seconds to 2 seconds by cutting
iterations, despite adding TDB_VERSION1 tests.
2) api-missing-entries: reduce from 17 seconds to under 1 second by
not checking db inside loop, but at end.
This reduces the total ccanlint time from 729 to 489 seconds.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit a99c2ccf97465d47c3277d997ea93f20ff97ad4d)
|
|
This reduces compilation time, since these are merely linked with the
pre-built module, rather than recompiling it into the test (which
allows for fancy things like failtest).
This reduces the test compile time down from about 62 seconds to 45
seconds. Since ccanlint compiles tests three times (once normally,
once with coverage, and once with reduced config.h) this makes a
difference: we go from 780 seconds to 729 seconds.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit c4ca9f54301c0367891be6330f59fdd5dcdd51d1)
|
|
We track malloc and free, but we didn't catch the free() inside
external_agent, which means that our list of allocations keeps
growing. Particularly under valgrind, which re-uses memory less than
the glibc allocator.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit d9cbd7d4454ae35e4e2f6d18a9469bf26948e4b9)
|
|
The TDB1 code's tdb1_find() returns 0 on error; the callers should
not assume that the error means that the entry wasn't found, but use
last_error to determine it.
This was found by looking at how long the failure path testing for
test/run-10-simple-store.c was taking under valgrind, ie:
valgrind -q ./run-10-simple-store --show-slowest
This change dropped the time for that test from 53 seconds to 19
seconds.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit 1be090a2d749713cfd0c4584cafb97bffd716189)
|
|
There are some minor changes required, in particular:
1) Make sure lockcheck understands tdb1 allrecord lock upgrades.
2) Handle tdb1 sequence number jumps: various operations increment the
sequence number twice, especually tdb_append.
3) Don't test fail on unlock, since it gets triggered with traversal on the
tdb1 backend (we didn't actually ever test this case for tdb2).
4) Move clear_if_first to offset 4, to match tdb1.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
(Imported from CCAN commit 818ed29730b030ce79855fc35c212b51adff3180)
|