Andreas Schneider [Mon, 18 Feb 2013 16:11:15 +0000 (17:11 +0100)]
libsmb: Fix possible null pointer dereference.
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Andreas Schneider [Mon, 18 Feb 2013 16:08:21 +0000 (17:08 +0100)]
ndr: Comparing an array to null is always true.
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Andreas Schneider [Mon, 18 Feb 2013 15:24:38 +0000 (16:24 +0100)]
winbind: Correctly cast name to messaging_send_buf().
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Andreas Schneider [Mon, 18 Feb 2013 14:48:24 +0000 (15:48 +0100)]
winbind: Use uint8_t type and use const where needed.
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Andreas Schneider [Mon, 18 Feb 2013 14:46:52 +0000 (15:46 +0100)]
messages: Use uint8_t type.
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Andreas Schneider [Mon, 18 Feb 2013 14:44:20 +0000 (15:44 +0100)]
winbind: Make domain_name const in wcache_ndr_key().
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Björn Jacke [Tue, 19 Feb 2013 18:09:25 +0000 (19:09 +0100)]
build: use -fstack-protector if available
Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Matthieu Patou <mat@samba.org>
Autobuild-User(master): Björn Jacke <bj@sernet.de>
Autobuild-Date(master): Fri Feb 22 15:38:21 CET 2013 on sn-devel-104
Björn Jacke [Tue, 19 Feb 2013 18:07:34 +0000 (19:07 +0100)]
Revert "wafbuild: use -Wstack-protector if available"
This reverts commit
e6643fbf48afccd0acedb65fbe24d3ce84d44c40.
Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Matthieu Patou <mat@samba.org>
Björn Jacke [Wed, 20 Feb 2013 16:06:49 +0000 (17:06 +0100)]
build/autoconf: put ld check variable in quotes
Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Andrew Bartlett [Mon, 11 Feb 2013 03:46:43 +0000 (14:46 +1100)]
dsdb-descriptor: Avoid segfault copying an SD without an owner or group
This is an unusual SD, but it does exist is some very old upgraded databases.
Andrew Bartlett
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Fri Feb 22 11:06:17 CET 2013 on sn-devel-104
Andrew Bartlett [Mon, 11 Feb 2013 03:45:57 +0000 (14:45 +1100)]
dsdb-descriptor: Spell out security descriptor flags as constants
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Andrew Bartlett [Tue, 15 Jan 2013 21:52:41 +0000 (08:52 +1100)]
torture-drs: Fix comment in replica_sync test
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Andrew Bartlett [Thu, 7 Feb 2013 08:35:15 +0000 (19:35 +1100)]
torture-drs: Make the samba4.drs.repl_schema.python emit failures, not errors on add failure
This then allows this particular failure to be masked with a knownfail.
Andrew Bartlett
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Andrew Bartlett [Fri, 15 Feb 2013 02:32:06 +0000 (13:32 +1100)]
ldb: Add missing dependency on replace for ldb
This brings in rep_timegm() on Solaris for example.
Andrew Bartlett
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Andrew Bartlett [Tue, 19 Feb 2013 00:44:19 +0000 (11:44 +1100)]
build: Remove includes.h dep in winbind client libraries
Our LGPL winbind client libs do not link against our server-side code, and
should not use the server-side includes.h.
This removes a build-time dep on talloc that was brought in via includes.h as
this code also does not use talloc.
Andrew Bartlett
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Andrew Bartlett [Tue, 19 Feb 2013 00:15:20 +0000 (11:15 +1100)]
build: Remove unused includes.h reference to avoid build-time talloc dep
talloc is not a dependency of this library, but is required by includes.h.
By not including includes.h, we avoid needing to add an otherwise false talloc dep.
(this comes up if talloc.h is not installed as a system package).
Andrew Bartlett
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Björn Jacke [Wed, 20 Feb 2013 18:57:24 +0000 (19:57 +0100)]
build:autoconf: fix output of syslog-facility check
thanks to Thomas Bork for reporting!
Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Thu Feb 21 00:00:06 CET 2013 on sn-devel-104
Christian Ambach [Wed, 20 Feb 2013 15:59:05 +0000 (16:59 +0100)]
s3:rpc_client fix a crash
state->cli->dc does not have to be set (e.g. when running
net rpc join against an older Samba PDC), so check it before dereferencing it
This fixes Bug 9669 - net rpc join crashes against a Samba 3.0.33 PDC
Bug: https://bugzilla.samba.org/show_bug.cgi?id=9669
Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Christian Ambach <ambi@samba.org>
Autobuild-Date(master): Wed Feb 20 19:00:52 CET 2013 on sn-devel-104
Rusty Russell [Wed, 20 Feb 2013 04:29:42 +0000 (14:59 +1030)]
ntdb: switch between secrets.tdb and secrets.ntdb depending on 'use ntdb'
Since we open with dbwrap, it auto-converts old tdbs (which it will
rename to secrets.tdb.bak once it's done).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Rusty Russell <rusty@rustcorp.com.au>
Autobuild-Date(master): Wed Feb 20 07:09:19 CET 2013 on sn-devel-104
Rusty Russell [Wed, 20 Feb 2013 04:29:42 +0000 (14:59 +1030)]
param: 'use ntdb' flag (off by default).
For simplicity, we use this in the caller to choose between filenames.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Rusty Russell [Wed, 20 Feb 2013 04:29:42 +0000 (14:59 +1030)]
tdb_wrap: prevent tdbs called ".ntdb" or without extensions.
This is another belt-and-braces check in case someone decides to turn
on the fancy new .ntdb extension, and we haven't converted it to ntdb.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Rusty Russell [Wed, 20 Feb 2013 04:29:42 +0000 (14:59 +1030)]
dbwrap_local_open: never open the .tdb if there is an .ntdb
This provides an extra safety check that everyone is using one or the
other: you can't create a tdb file if there's an ntdb file.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Rusty Russell [Wed, 20 Feb 2013 04:29:42 +0000 (14:59 +1030)]
dbwrap_local_open: open NTDB if extension is .ntdb
This switches dbwrap_local_open() based on the extension of the
database name, so it handles both TDB and NTDB files.
Moreover, if asked to open a .ntdb, and there's no ntdb file but
there's a .tdb file, it converts that then moves it to .tdb.bak before
opening, and turn the .tdb file into a dangling symlink to make sure
it's never accidentally re-created or used:
$ ls -l secrets.tdb
lrwxrwxrwx 1 rusty rusty 23 Feb 11 11:31 secrets.tdb -> This is now in an NTDB
This provides transparent upgrade if people decide to use NTDB on a
database. Downgrade would be manual, eg:
ntdbdump foo.ntdb | tdbrestore foo.tdb && mv foo.ntdb foo.ntdb.bak
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Rusty Russell [Wed, 20 Feb 2013 04:29:42 +0000 (14:59 +1030)]
source3: explicitly disable NTDB support.
The next patch make dbwrap_local_open() call the ntdb backend for ntdb
files, but we don't want to add ntdb support to the old autoconf
build. It's cleaner to use the existing DISABLE_NTDB flag rather than
test for _SAMBA_BUILD_ in dbwrap_local_open.c.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Rusty Russell [Wed, 20 Feb 2013 04:28:59 +0000 (14:58 +1030)]
dbwrap: dbwrap_ntdb.c
This is a dbwrap backend for ntdb. It's a fairly straight conversion from
the tdb version.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Rusty Russell [Sun, 17 Feb 2013 10:26:34 +0000 (20:56 +1030)]
ntdb: fix database corruption when transaction doesn't change anything.
ntdb's transaction code has an optimization which tdb's doesnt: it
only writes the parts of blocks whose contents have changed. This
means we can actually have a transaction which turns out to need no
recovery region.
This breaks the recovery setup logic, which sets the current recovery
size to 0 if there's no recovery area, and assumes that we'll always
create a new recovery area since the recovery will always need > 0
bytes.
In fact, if we really haven't changed anything, we can skip the
transaction commit altogether: since this happens at least once with
Samba, it's worth doing.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Stefan Metzmacher [Fri, 15 Feb 2013 13:29:51 +0000 (14:29 +0100)]
s3:selftest: generate ${SELFTESTPREFIX}/subunit with the raw output
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Wed Feb 20 01:33:50 CET 2013 on sn-devel-104
Stefan Metzmacher [Fri, 15 Feb 2013 13:23:50 +0000 (14:23 +0100)]
s3:torture: call fault_setup() to get usage backtraces
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 10:04:18 +0000 (11:04 +0100)]
s3:include: avoid TEVENT_COMPAT_DEFINES
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:57:54 +0000 (10:57 +0100)]
s3:lib: s/event_add_timed/tevent_add_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:57:54 +0000 (10:57 +0100)]
s3:nmbd: s/event_add_timed/tevent_add_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:57:54 +0000 (10:57 +0100)]
s3:modules: s/event_add_timed/tevent_add_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:57:54 +0000 (10:57 +0100)]
s3:rpc_server: s/event_add_timed/tevent_add_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:57:54 +0000 (10:57 +0100)]
s3:winbindd: s/event_add_timed/tevent_add_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:53:02 +0000 (10:53 +0100)]
s3:lib: s/event_add_fd/tevent_add_fd and s/EVENT_FD_/TEVENT_FD_
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:53:02 +0000 (10:53 +0100)]
s3:printing: s/event_add_fd/tevent_add_fd and s/EVENT_FD_/TEVENT_FD_
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:53:02 +0000 (10:53 +0100)]
s3:smbd: s/event_add_fd/tevent_add_fd and s/EVENT_FD_/TEVENT_FD_
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:53:02 +0000 (10:53 +0100)]
s3:modules: s/event_add_fd/tevent_add_fd and s/EVENT_FD_/TEVENT_FD_
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:24:12 +0000 (10:24 +0100)]
s3:lib: s/struct fd_event/struct tevent_fd
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:24:12 +0000 (10:24 +0100)]
s3:modules: s/struct fd_event/struct tevent_fd
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:24:12 +0000 (10:24 +0100)]
s3:printing: s/struct fd_event/struct tevent_fd
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:24:12 +0000 (10:24 +0100)]
s3:smbd: s/struct fd_event/struct tevent_fd
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:18:29 +0000 (10:18 +0100)]
s3:lib: s/struct timed_event/struct tevent_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:18:29 +0000 (10:18 +0100)]
s3:nmbd: s/struct timed_event/struct tevent_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:18:29 +0000 (10:18 +0100)]
s3:modules: s/struct timed_event/struct tevent_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:18:29 +0000 (10:18 +0100)]
s3:rpc_server: s/struct timed_event/struct tevent_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:18:57 +0000 (10:18 +0100)]
s3:smbd: s/EVENT_FD/TEVENT_FD
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:18:29 +0000 (10:18 +0100)]
s3:smbd: s/struct timed_event/struct tevent_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:17:40 +0000 (10:17 +0100)]
s3:winbindd: s/struct timed_event/struct tevent_timer
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:16:48 +0000 (10:16 +0100)]
s3:lib/events: s/EVENT_FD/TEVENT_FD
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 09:00:26 +0000 (10:00 +0100)]
s3:lib: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:59:58 +0000 (09:59 +0100)]
s3:libsmb: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:59:08 +0000 (09:59 +0100)]
s3:modules: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:58:40 +0000 (09:58 +0100)]
s3:nmbd: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:58:10 +0000 (09:58 +0100)]
s3:printing: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:57:48 +0000 (09:57 +0100)]
s3:rpc_server: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:57:22 +0000 (09:57 +0100)]
s3:rpc_client: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:56:41 +0000 (09:56 +0100)]
s3:smbd: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:55:58 +0000 (09:55 +0100)]
s3:torture: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:55:02 +0000 (09:55 +0100)]
s3:winbindd: s/struct event_context/struct tevent_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:21:53 +0000 (09:21 +0100)]
s3:includes: remove event_context_init() define for s3_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:12:26 +0000 (09:12 +0100)]
s3:winbindd: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:17:45 +0000 (09:17 +0100)]
s3:rpc_client: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:11:19 +0000 (09:11 +0100)]
s3:torture: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:11:52 +0000 (09:11 +0100)]
s3:utils: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:17:22 +0000 (09:17 +0100)]
s3:libnet: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:10:34 +0000 (09:10 +0100)]
s3:lib: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:09:57 +0000 (09:09 +0100)]
s3:libads: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:08:19 +0000 (09:08 +0100)]
s3:libsmb: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:13:23 +0000 (09:13 +0100)]
s4:lib/com: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:12:58 +0000 (09:12 +0100)]
s4:auth/kerberos: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:09:31 +0000 (09:09 +0100)]
librpc/rpc: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:07:11 +0000 (09:07 +0100)]
libcli/smb: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 08:06:29 +0000 (09:06 +0100)]
libcli/cldap: make use of samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Stefan Metzmacher [Mon, 18 Feb 2013 07:54:51 +0000 (08:54 +0100)]
lib/util: add samba_tevent_context_init()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Björn Jacke [Tue, 19 Feb 2013 14:30:34 +0000 (15:30 +0100)]
build/autoconf: fix check for GNU ld version
we need to look for the version once in the stdout and once in the stderr
output. Some version of ld output to stdout, some output to stderr. redirecting
stderr to stdout messes the output up in our case, that's why we have to do two
runs. See also bug #7825.
Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Björn Jacke <bj@sernet.de>
Autobuild-Date(master): Tue Feb 19 20:56:12 CET 2013 on sn-devel-104
Christian Ambach [Mon, 18 Feb 2013 16:34:25 +0000 (17:34 +0100)]
s3:build fix the build with --fake-kaserver
this fixes Bug 9643 - Build in source3 of bin/net fails when configure option
--with-fake-kaserver is used
Bug: https://bugzilla.samba.org/show_bug.cgi?id=9643
Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Tue Feb 19 19:15:19 CET 2013 on sn-devel-104
Christian Ambach [Mon, 18 Feb 2013 15:55:30 +0000 (16:55 +0100)]
s3:lib/afs fix the build
Fix Bug 9644 - Compile of source3/lib/afs.c fails
Bug: https://bugzilla.samba.org/show_bug.cgi?id=9644
Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Volker Lendecke [Tue, 19 Feb 2013 11:23:36 +0000 (12:23 +0100)]
tdb: Slightly simplify transaction_write
realloc(NULL, ...) is equivalent to malloc. We are already using this
realloc property for tdb->lockrecs. It should not make any difference
in speed, it just makes for a little simpler code.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue Feb 19 17:30:13 CET 2013 on sn-devel-104
Volker Lendecke [Sat, 16 Feb 2013 21:08:52 +0000 (22:08 +0100)]
tdb: Make tdb_release_transaction_locks use tdb_allrecord_unlock
The transaction code uses tdb_alrecord_lock/upgrade, so it should also
use the tdb_allrecord_unlock function just for symmetry reasons
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Volker Lendecke [Sat, 16 Feb 2013 21:07:41 +0000 (22:07 +0100)]
tdb: Don't segfault if tdb_open_ex for check failed
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Volker Lendecke [Sat, 16 Feb 2013 15:49:56 +0000 (16:49 +0100)]
tdb: Factor out the retry loop from tdb_allrecord_upgrade
For the mutex code we will have to lock the hashchain and the record
lock area independently. So we will have to call the loop twice. And,
it's a small refactoring for the better anyway I think.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Volker Lendecke [Sat, 16 Feb 2013 13:17:57 +0000 (14:17 +0100)]
tdb: Simplify fcntl_lock() a bit
All arguments but the cmd are the same. To me this looks a bit better
and saves some bytes in the object code.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Volker Lendecke [Sat, 16 Feb 2013 12:39:28 +0000 (13:39 +0100)]
tdb: Use tdb_null in freelistcheck
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Volker Lendecke [Thu, 14 Feb 2013 15:10:31 +0000 (16:10 +0100)]
tdb: Enhance lock tracking a bit
lock-tracking.c mirrors the in-kernel fcntl structures to detect
unexpected use of fcntl calls. During my mutex work I changed our fcntl
use so that we unlock the allrecord_lock in two pieces: The range covering
the hash locks and the range covering the data area for the individual
traverse record locks. Splitting locks is not covered by lock-tracking.c.
This patch extends lock-tracking.c with this little piece. It's still
far from complete to track the full range of fcntl semantics. It is not
strictly needed right now, but it does not hurt either.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Tue, 19 Feb 2013 12:27:10 +0000 (13:27 +0100)]
s3:smbd: preserve file type mode bits in file_set_dosmode()
When translating between dos modes and unix modes, these bits were dropped from
the stat->st_ex_mode field.
Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Tue Feb 19 15:45:31 CET 2013 on sn-devel-104
Michael Adam [Wed, 13 Feb 2013 08:46:33 +0000 (09:46 +0100)]
gencache: fix an extra newline in a DEBUG message in gencache_set_data_blob()
by using timestring() instead of ctime()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Wed, 13 Feb 2013 08:45:09 +0000 (09:45 +0100)]
gencache: fix an extra newline in a DEBUG message in gencache_iterate_fn()
by using timestring() instead of ctime()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Wed, 13 Feb 2013 08:43:19 +0000 (09:43 +0100)]
gencache: fix an extra newline in a DEBUG message in gencache_iterate_blobs_fn()
by using timestring() instead of ctime()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Wed, 13 Feb 2013 15:51:54 +0000 (16:51 +0100)]
lib/util/time: strip a potential trailing newline in the asctime case.
If strftime() is not available, asctime() is used, and this usually
appends a newline character to the result. This is not desired for
timestamp().
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Mon, 11 Feb 2013 12:41:12 +0000 (13:41 +0100)]
gencache: unify a DEBUG message in gencache_set_data_blob()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Mon, 11 Feb 2013 12:42:58 +0000 (13:42 +0100)]
gencache: unify a DEBUG message in gencache_iterate_fn()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Mon, 11 Feb 2013 12:42:28 +0000 (13:42 +0100)]
gencache: unify a DEBUG message in gencache_iterate_blobs_fn()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Mon, 11 Feb 2013 12:43:32 +0000 (13:43 +0100)]
gencache: unify a DEBUG message in gencache_del()
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Thu, 25 Oct 2012 09:35:50 +0000 (05:35 -0400)]
packaging(RHEL-CTDB): remove unpackaged manpages (samba and samba-tool)
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Michael Adam [Thu, 25 Oct 2012 09:34:23 +0000 (05:34 -0400)]
packaging(RHEL-CTDB): package the fake-acls vfs module
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Gregor Beck [Thu, 13 Dec 2012 12:00:28 +0000 (13:00 +0100)]
s3:net: new implementation of "servid wipedbs" with smbXsrv_*
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Tue Feb 19 13:56:57 CET 2013 on sn-devel-104
Gregor Beck [Thu, 10 Jan 2013 10:09:09 +0000 (11:09 +0100)]
lib/util_tdb: factor out tdb_data_talloc_copy()
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Gregor Beck [Wed, 12 Dec 2012 15:06:50 +0000 (16:06 +0100)]
s3:smbXsrv_open: add smbXsrv_open_global_traverse()
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Gregor Beck [Thu, 13 Dec 2012 14:27:07 +0000 (15:27 +0100)]
s3:smbXsrv_tcon: pass record in smbXsrv_tcon_global_traverse()
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>