1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00
Commit Graph

93835 Commits

Author SHA1 Message Date
Michael Adam
925625b528 dbwrap_ctdb: avoid smbd/ctdb deadlocks: check whether we can work locally in db_ctdb_parse_record()
If the same process tries to re-lock the same record
it has already locked, don't go to the ctdbd again.

There are situations where we already have a lock on a record
and then do a dbwrap_parse_record() on that record, for instance
in locking code:

do_lock()
  -> grabs lock on brl record with brl_get_locks()
    -> calls brl_lock()
      -> calls brl_lock_posix or _windows_default()
        -> calls contend_level2_oplocks_begin()
          -> calls brl_locks_get_read_only()
            -> calls dbwrap_parse_record on the same brl record as above

In the local (tdb) case, this is not a problem, because
identical fcntl locks in the same process don't contend each other,
but calling out to ctdb for this lets smbd and ctdb deadlock.

db_ctdb_fetch_lock() already correclty checks first
whether we can simply try to lock locally. But db_ctdb_parse_record()
failed to do so for empty records, i.e. records that only
consist of the ctdb record header. (These can be deleted records
but can also be freshly created and still empty records.)

This patch lets db_ctdb_parse_record() not skip local access
for empty records, hence fixing the deadlock.

PLAN: In the long run, it would be better to solve this
generically on the dbwrap_layer, i.e. root the notion of
an already locked record there, and skip any call to the
db (tdb or ctdb backend) if we have it. This would also
solve the problem for all calls like fetch_locked, parse_record
and possibly others.  But this is the urgent fix for now.

Pair-Programmed-With: Volker Lendecke <vl@samba.org>
Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Volker Lendecke <vl@samba.org>
Tested-by: Björn Baumbach <bb@sernet.de>
2014-03-03 12:56:38 +01:00
Volker Lendecke
7e5350602e torture: Fix a torture crash with -O3
When compiled with -O3, smbtorture can crash after the following valgrind
trace:

==16944== Conditional jump or move depends on uninitialised value(s)
==16944==    at 0x57FFAC3: ndr_push_unique_ptr (ndr_basic.c:730)
==16944==    by 0x58CB855: ndr_push_spoolss_SetPrinterInfo (ndr_spoolss.c:7939)
==16944==    by 0x58E2F95: ndr_push_spoolss_SetPrinter (ndr_spoolss.c:24724)
==16944==    by 0x417C78C: dcerpc_binding_handle_call_send (binding_handle.c:410)
==16944==    by 0x417C986: dcerpc_binding_handle_call (binding_handle.c:547)
==16944==    by 0x522059C: dcerpc_spoolss_SetPrinter_r (ndr_spoolss_c.c:1722)
==16944==    by 0x2853BD: test_sd_set_level (spoolss.c:1248)
==16944==    by 0x28F146: test_PrinterInfo_SD (spoolss.c:1962)
==16944==    by 0x2A3C31: test_EnumPrinters_old (spoolss.c:6589)
==16944==    by 0x41F6D66: internal_torture_run_test.part.0 (torture.c:442)
==16944==    by 0x41F711F: torture_run_tcase_restricted (torture.c:758)
==16944==    by 0x2018E8: run_matching.isra.1 (smbtorture.c:103)
==16944==    by 0x20176B: run_matching.isra.1 (smbtorture.c:95)
==16944==    by 0x20176B: run_matching.isra.1 (smbtorture.c:95)
==16944==    by 0x201C12: torture_run_named_tests (smbtorture.c:143)
==16944==    by 0x202F5B: main (smbtorture.c:661)

My assumption is that with optimization gcc makes use of the fact that the
structures that this patch moves go out of scope.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>

Autobuild-User(master): David Disseldorp <ddiss@samba.org>
Autobuild-Date(master): Fri Feb 28 21:27:11 CET 2014 on sn-devel-104
2014-02-28 21:27:11 +01:00
Volker Lendecke
1dd2351840 torture: Fix a buffer overrun
In test_EnumPrinterDrivers we go up to driver level 8. In C, this means
we are accessing the 9th entry in the following lines:

        ctx->driver_count[level]        = count;
        ctx->drivers[level]             = info;

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
2014-02-28 17:49:01 +01:00
David Disseldorp
ca3998d043 vfs: propagate snapshot enumeration errors
The current FSCTL_GET_SHADOW_COPY_DATA/FSCTL_SRV_ENUMERATE_SNAPSHOTS
handler squashes all non-ENOSYS errors into an NT_STATUS_UNSUCCESSFUL
response.
This commit ensures that all errors are propagated up to the client, to
aid debugging.
The Windows Explorer "Previous Versions" dialogue doesn't appear to
distinguish between error codes. It displays "There are no previous
versions available".

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Thu Feb 27 22:42:50 CET 2014 on sn-devel-104
2014-02-27 22:42:50 +01:00
Jeremy Allison
abf08ed544 s3: smbd: Ensure brl_get_locks_readonly() always returns a valid struct byte_range_lock even if there are no locks.
brl_get_locks_readonly() currently returns NULL when it can't
find any byte range locks on the file. This is an error - it
should return a valid struct byte_range_lock containing num_locks == 0
so it can be cached.

Returning NULL when there are no locks causes POSIX lock
tests to fail returning NT_STATUS_NO_MEMORY (as it thinks
it can't allocate the struct) instead of NT_STATUS_OK.

Fixes bug:

Bug 10431 - STATUS_NO_MEMORY response from Query File Posix Lock request

https://bugzilla.samba.org/show_bug.cgi?id=10431

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE>
2014-02-27 10:42:36 -08:00
Andreas Schneider
f0030c619b pidl: Make perl(Parse:Yapp:Driver) installation optional.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=10472

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jelmer Vernooij <jelmer@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Thu Feb 27 18:47:03 CET 2014 on sn-devel-104
2014-02-27 18:47:03 +01:00
Andreas Schneider
562ade624a s3-spoolssd: Don't register spoolssd if epmd is not running.
https://bugzilla.samba.org/show_bug.cgi?id=10474

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2014-02-27 16:47:47 +01:00
Amitay Isaacs
7d05baa96b ctdb-recoverd: Check if callback function is registered before calling
Fix suggested by by Kevin Osborn <kosborn@overlandstorage.com>.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>

Autobuild-User(master): Martin Schwenke <martins@samba.org>
Autobuild-Date(master): Thu Feb 27 13:54:59 CET 2014 on sn-devel-104
2014-02-27 13:54:59 +01:00
Amitay Isaacs
026996550d ctdb-daemon: After updating tickles on other nodes, set update flag to false
tcp_update_flag is set to true whenever tickles are added or deleted.
This flag is used to determine whether or not to send tickles list to
other nodes.  Once tickles list is sent to other nodes successfully,
set tcp_update_flag to false, so ctdbd does not keep sending same tickles
list every TickleUpdateInterval (20 seconds).

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
2014-02-27 11:49:39 +01:00
Martin Schwenke
0723fedced ctdb-daemon: Implement ctdb_control_startup()
This doesn't implement what was recommended.  That would require
careful error handling, probably with a fallback to this code anyway.
This is simple and does no worse that the current code.  That is, the
new node is updated on the next call to tdb_update_tcp_tickles().

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
2014-02-27 11:49:39 +01:00
Amitay Isaacs
75ca1216a6 ctdb-daemon: Fix whitespaces
Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
2014-02-27 11:49:39 +01:00
Amitay Isaacs
f2cd999189 ctdb-daemon: Always talloc tickle array off vnn instead of ctdb->nodes
This fixes ctdb crash reported in bug #10366.
Fix suggested by Kevin Osborn <kosborn@overlandstorage.com>.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
2014-02-27 11:49:39 +01:00
Andreas Schneider
9b200555fe waf: Add option to specify perl vendor dir.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=10472

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Kai Blin <kai@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Thu Feb 27 11:48:54 CET 2014 on sn-devel-104
2014-02-27 11:48:54 +01:00
Andreas Schneider
cee11cfa45 pidl: Install pidl files corrently.
Globbing is a really bad idea in installtion system. One of them is if
you use patch -b to create a backup, you will end up installing the
backup file too!

BUG: https://bugzilla.samba.org/show_bug.cgi?id=10472

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Kai Blin <kai@samba.org>
2014-02-26 13:10:58 +01:00
Volker Lendecke
5e07731cf6 dbwrap: Slightly simplify dbwrap_watch_record_stored
We have messaging_send_buf, so there's no point to use an explicit
DATA_BLOB here.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Feb 25 23:27:21 CET 2014 on sn-devel-104
2014-02-25 23:27:21 +01:00
Jose A. Rivera
64bae74f56 vfs_glusterfs: Remove "integer fd" code and store the glfs pointers.
Change-Id: I74347199e54be0d1dc031985534da1e56fd3e280
Signed-off-by: Jose A. Rivera <jarrpa@redhat.com>
Reviewed-by: Christopher R. Hertel <crh@samba.org>
Reviewed-by: Ira Cooper <ira@samba.org>
2014-02-25 12:27:51 -08:00
Christopher R. Hertel
86aa43c73c vfs_glusterfs: smb_stat_ex_from_stat commenting and cleanup.
Change-Id: If1b54e62b4fc2240aa17e5d1eae8f279f2fdfc42
Signed-off-by: Christopher R. Hertel <crh@samba.org>
Reviewed-by: Jose A. Rivera <jarrpa@redhat.com>
Reviewed-by: Ira Cooper <ira@samba.org>
2014-02-25 12:27:51 -08:00
Christopher R. Hertel
910a56a7cb vfs_glusterfs: Comment the top of the file.
Change-Id: I98b512da2e0e56f061247a7c48ce576287b43827
Signed-off-by: Christopher R. Hertel <crh@samba.org>
Reviewed-by: Jose A. Rivera <jarrpa@redhat.com>
Reviewed-by: Ira Cooper <ira@samba.org>
2014-02-25 12:27:40 -08:00
Jeremy Allison
148bbdd8d0 s3-printing: Fix obvious memory leak in printer_list_get_printer().
https://bugzilla.samba.org/show_bug.cgi?id=9993

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ira Cooper <ira@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Tue Feb 25 13:19:37 CET 2014 on sn-devel-104
2014-02-25 13:19:37 +01:00
Michael Adam
e35b1d8dc4 passdb: spare superfluous call to lookup_rids() in lookup_sids()
If we have no name indexes for a domain, all names were domain
names and have been resolved earlier, including the domain name.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10463

Change-Id: I5a7a387fa89d2b2bdd465c13b3dca0e18ca0482c
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue Feb 25 11:17:18 CET 2014 on sn-devel-104
2014-02-25 11:17:18 +01:00
Michael Adam
0cb15c169f rpc: fix name-normalization in rpc_sid_to_name()
Hand the *input* name as input into the normalize call,
not the (potentially uninitialized...) *output* name...

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10463

Change-Id: I4f3fc25882c22d96329e252d0a53bbe13d533472
Pair-Programmed-With: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2014-02-25 09:17:07 +01:00
Michael Adam
ab7992b5bf rpc: correctly tread domain-only requests in rpc_sid_to_name()
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10463

Change-Id: I6a8a8c272b9cf7dbce4f9a99012209c29c31e839
Pair-Programmed-With: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2014-02-25 09:17:07 +01:00
Stefan Metzmacher
8fec421543 samr: don't block the sam sid or the builtin domain sid in sid_to_name
Previously only members of these domains were handled.
But we also need to handle the domain itself.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10463

Change-Id: I44f85267eda243d586fffd24a799e153de0ff982
Pair-Programmed-With: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Stefan Metzmacher <metze@sernet.de>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-02-25 09:17:07 +01:00
Martin Schwenke
fcf846a795 ctdb-eventscripts: Switch on dumping of stuck nfsd threads
This feature was added quite a while ago but was not enabled by
default.  It is a useful feature so enable it to dump stack traces of
up to 5 stuck processes by default.

This can be disabled by setting:

  CTDB_NFS_DUMP_STUCK_THREADS=0

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>

Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Tue Feb 25 04:06:45 CET 2014 on sn-devel-104
2014-02-25 04:06:45 +01:00
Garming Sam
695ece206b s4: tidy up vfs smb2 in regards to using share_string_option
Change-Id: Ieae6b5ddc2cd9983489c374605e4740371e81883
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Kamen Mazdrashki <kamenim@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Mon Feb 24 19:16:48 CET 2014 on sn-devel-104
2014-02-24 19:16:48 +01:00
Garming Sam
d8d06193da s4: tidy up vfs cifs in regards to using share_string_option
Change-Id: I014bce667d3f875a913dbccf269b514f7ffbab7b
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Kamen Mazdrashki <kamenim@samba.org>
2014-02-24 17:17:03 +01:00
Garming Sam
209386bbd3 s4: tidy up some null checks in ntvfs
Change-Id: I629a299bea10b063de4525020a4c6b838260cd67
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Kamen Mazdrashki <kamenim@samba.org>
2014-02-24 17:16:27 +01:00
Ira Cooper
8cd8aa6686 libcli: Overflow array index read possible, in auth code.
Changed the if condtion to detect when we'd improperly overflow.

Coverity-Id: 1167990
Signed-off-by: Ira Cooper <ira@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User(master): Ira Cooper <ira@samba.org>
Autobuild-Date(master): Mon Feb 24 11:56:38 CET 2014 on sn-devel-104
2014-02-24 11:56:37 +01:00
Ira Cooper
14063719e0 Revert "libcli: Overflow array index read possible, in auth code."
This reverts commit 538cbfe0e9.

Signed-off-by: Ira Cooper <ira@samba.org>
2014-02-24 14:16:00 +05:30
Ira Cooper
538cbfe0e9 libcli: Overflow array index read possible, in auth code.
The values have to be signed here to allow for the values to go negative,
to prevent the overflow.

Coverity-Id: 1167990
Signed-off-by: Ira Cooper <ira@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User(master): Ira Cooper <ira@samba.org>
Autobuild-Date(master): Mon Feb 24 07:23:03 CET 2014 on sn-devel-104
2014-02-24 07:23:03 +01:00
Poornima Gurusiddaiah
72f9932d4f s3:printing: Fix a possible NULL dereference.
Coverity-Id: 710708

Signed-off-by: Poornima Gurusiddaiah <pgurusid@redhat.com>
Reviewed-by: Ira Cooper <ira@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2014-02-24 09:51:31 +05:30
Poornima Gurusiddaiah
68d5f27464 s3:passdb: Fix the use of uninitialized scalar variable.
Coverity-id: 1107228,1107227

Signed-off-by: Poornima Gurusiddaiah <pgurusid@redhat.com>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ira Cooper <ira@samba.org>
2014-02-24 09:43:44 +05:30
Jose A. Rivera
2b77b07286 s3/libsmb: Free memdup'd local variable
secrets_fetch_machine_password() sets pwd to point to memdup()'d (and thus
malloc()'d) memory. This memory should be freed before we go out of scope.

Change-Id: I07e575819c309fa5b85627dce2eb969bc720ce4e
Coverity-Id: 1168001
Reviewed-by: Ira Cooper <ira@samba.org>
Signed-off-by: Jose A. Rivera <jarrpa@redhat.com>
Reviewed-by: Simo Sorce <idra@samba.org>

Autobuild-User(master): Simo Sorce <idra@samba.org>
Autobuild-Date(master): Sat Feb 22 00:58:23 CET 2014 on sn-devel-104
2014-02-22 00:58:23 +01:00
Jose A. Rivera
9a9e56943d passdb: Patch memory leak in pdb_ldap.c
Moved the call to the talloc autofree function to as early a point as
possible. init_ldap_from_sam() already calls smbldap_set_mod(), and there's
a chance that the init will fail after having already allocated memory for
&mods.

Coverity-Id: 1167997
Change-Id: Ic26bfb3c530f90aa885e447b8409deba49708d64
Reviewed-by: Ira Cooper	<ira@samba.org>
Signed-off-by: Jose A. Rivera <jarrpa@redhat.com>
Reviewed-by: Simo Sorce <idra@samba.org>
2014-02-21 16:55:47 -05:00
Andreas Schneider
293aac0508 testprogs: Fix pkinit test with system ldb.
Reviewed-by: Alexander Bokovoy <ab@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Fri Feb 21 17:58:24 CET 2014 on sn-devel-104
2014-02-21 17:58:24 +01:00
Andreas Schneider
069015bee9 testprogs: Fix kinit test with system ldb.
Reviewed-by: Alexander Bokovoy <ab@samba.org>
2014-02-21 15:59:28 +01:00
Andreas Schneider
f26db53273 nsswitch: Fix idmap rfc2307 test with system ldb.
Reviewed-by: Alexander Bokovoy <ab@samba.org>
2014-02-21 15:59:28 +01:00
Andreas Schneider
153dfc514c selftest: Use the absolute path to the ldb modules.
This fixes 'make test' on Fedora with external ldb.

Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
2014-02-21 15:59:28 +01:00
Santosh Kumar Pradhan
d871a31e61 heimdal: Use krb5_free_default_realm() for free()
The resource allocated by krb5_default_default_realm() should be
free()'d by krb5_free_default_realm() instead of plain free()
for better readability.

Signed-off-by: Santosh Kumar Pradhan <spradhan@redhat.com>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-02-21 15:59:28 +01:00
Santosh Kumar Pradhan
58e7e564d7 kdc: Free the resource which is not used anymore
In samba_kdc_firstkey() routine, krb5_get_default_realm() allocates
memory for "realm" but never used afterwards. Free() the leaked memory.

CID: 1107223

Signed-off-by: Santosh Kumar Pradhan <spradhan@redhat.com>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-02-21 15:59:28 +01:00
Gregor Beck
66fb0ce955 s3:winbindd: avoid directly asking a trusted domain in wb_lookupsids*()
As a domain member we should always use a DC of our own domain.

It would be possible to pass all sids in one single dcerpc_wbint_LookupSids()
call. For now we just fix bug.

Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10458
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-02-21 15:59:28 +01:00
Gregor Beck
3413e64149 s3:winbindd: fix _wbint_LookupSids() on error
We need to make sure that r->out.domains remains valid,
otherwise we're not able to marshall the response.

Note that wbint_LookupSids() has [out,ref] lsa_RefDomainList *domains,
while lsa_LookupSids() has [out,ref] lsa_RefDomainList **domains.

Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10458
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-02-21 15:59:28 +01:00
Stefan Metzmacher
33f10d06ba s3:smbd: avoid invalid lock_order panic triggered by "CTDB_SRVID_RELEASE_IP"
If smbd_server_connection_terminate("CTDB_SRVID_RELEASE_IP") is triggered from
within ctdbd_migrate(), we got a smb_panic complaining about invalid
lock_order, as ctdbd_migrate is called from dbwrap_fetch_locked().

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10444
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Fri Feb 21 14:51:51 CET 2014 on sn-devel-104
2014-02-21 14:51:51 +01:00
Stefan Metzmacher
9677fae6aa s3:lib/ctdbd_conn: let release_ip_handler return bool
If it returns true the passed ip address matched and we
let a nested ctdb operation fail with NT_STATUS_ADDRESS_CLOSED.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2014-02-21 12:48:31 +01:00
Stefan Metzmacher
52ccb40d59 s3:smbd: maintain smbd_server_connection->status
If this isn't NT_STATUS_OK, we skip any io on the socket.

This avoids possible problems during shutdown.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2014-02-21 11:48:12 +01:00
Stefan Metzmacher
58c71bee40 s3:smbd: simplify exit_server_common()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2014-02-21 11:47:18 +01:00
David Disseldorp
913b2a172d clitar: don't panic, propagate talloc errors upwards
Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Fri Feb 21 02:49:36 CET 2014 on sn-devel-104
2014-02-21 02:49:35 +01:00
David Disseldorp
83a653fadb clitar: propagate make_remote_path() talloc errors
Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2014-02-21 12:03:02 +13:00
David Disseldorp
55de6d60ef clitar: return allocation errors from is_subpath()
Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2014-02-21 12:02:57 +13:00
David Disseldorp
852259773b clitar: add error return to tar_path_in_list()
In preparation for propagation of memory allocation errors from
is_subpath().

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2014-02-21 12:02:52 +13:00