summaryrefslogtreecommitdiffstats
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* s3:param convert kernel oplocks to share parameterChristian Ambach2012-04-111-0/+1
| | | | Signed-off-by: Jeremy Allison <jra@samba.org>
* lib/tdb_compat: Do not define BUILD_TDB2 if we are not building tdb2Andrew Bartlett2012-04-111-3/+1
| | | | | | | The simple fact that this was defined at all, even to false, caused some of the tdb2 build code to run. Andrew Bartlett
* LDB:ldb_msg.c - add another OOM check in "ldb_msg_copy()"Matthias Dieter Wallnöfer2012-04-111-0/+1
|
* ccan: Fix failtest on Fedora 16 as stdlib.h does not imply malloc.hAndrew Bartlett2012-04-111-0/+4
| | | | | | | | The issue is that there are two different sources of the malloc prototype, and they both need to be included otherwise the failtest overrides chokes on the headers. Andrew Bartlett
* ldb-tools: Place the whole of an ldif file in a transactionAndrew Bartlett2012-04-107-16/+136
| | | | | | | | | | | | | | This ensures that when operating ldbadd and ldbmodify against local ldb files, either an ldif file succeeds or fails as a whole. Also tests to verify that this is working correctly, and an ABI bump due to the extra (private, but exported to ldb* tools) symbol and behaviour change. Andrew Bartlett Autobuild-User: Andrew Bartlett <abartlet@samba.org> Autobuild-Date: Tue Apr 10 11:14:43 CEST 2012 on sn-devel-104
* ldb: Allow access to the line number while reading ldif from a fileAndrew Bartlett2012-04-105-7/+281
|
* ldb: Detect failures in ldb.base againAndrew Bartlett2012-04-103-4/+15
| | | | | | | | | We need to wrap the ldb tests in the subunit blackbox helpers. We also needed to change to the right directory, or else the :< file:// syntax check does not work, as samba4.png is not found. Andrew Bartlett
* Revert "ldb: Permit desactivation of autocomit for every ldb_xxx_ctrl function"Andrew Bartlett2012-04-108-28/+23
| | | | | | | | | This reverts commit 40a4aea8918c2637703af03383f440d068820e48. Autocommit is important, as otherwise an ldb module could error out during an operation, and leave an corrupt database. Andrew Bartlett
* On advice from Jelmer and Andrew, move the blksize_t and blkcnt_t tests into ↵Jeremy Allison2012-04-103-8/+14
| | | | | | | libreplace to make it standalone. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Tue Apr 10 04:07:11 CEST 2012 on sn-devel-104
* Move blksize_t and blkcnt_t to replace.h from includes.h. Should help with ↵Jeremy Allison2012-04-092-0/+10
| | | | | | | platforms that don't have these. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Mon Apr 9 21:40:42 CEST 2012 on sn-devel-104
* libreplace: We have a poll replacement based on selectVolker Lendecke2012-04-091-0/+1
| | | | | Autobuild-User: Volker Lendecke <vl@samba.org> Autobuild-Date: Mon Apr 9 19:39:51 CEST 2012 on sn-devel-104
* tevent: Fix a typoVolker Lendecke2012-04-091-1/+1
|
* build: Remove sys_open wrapperAndrew Bartlett2012-04-051-1/+1
|
* build: do not use HAVE_EXPLICIT_LARGEFILE_SUPPORT and *64() fucntions any moreAndrew Bartlett2012-04-051-6/+1
|
* build: Remove configure tests for *64 functions and typesAndrew Bartlett2012-04-051-5/+0
| | | | | | We now use the standard types only. Andrew Bartlett
* lib/replace: Add getconf LFS_CFLAGS support to autoconf buildAndrew Bartlett2012-04-051-0/+8
|
* lib/util: charset modules do not exist any moreAndrew Bartlett2012-04-031-4/+0
| | | | | Autobuild-User: Andrew Bartlett <abartlet@samba.org> Autobuild-Date: Tue Apr 3 08:07:42 CEST 2012 on sn-devel-104
* lib/util: Add smb_load_module that returns DEBUG(0) errors on failureAndrew Bartlett2012-04-032-38/+39
| | | | | | | | These errors are very important when trying to work out why a module does not load, and this rework allows them to be shown when loading vfs modules. Andrew Bartlett
* Fix an IPv6 breakage I introduced by adding an strlcpy truncation check. ↵Jeremy Allison2012-03-311-3/+10
| | | | | | | | | | | Found by Matthieu Patou <mat@samba.org>. The truncate of the strlcpy() here was a *desired* side effect. strlcpy()/strlcat() should never be used like that. Be more explicit about the truncation and don't use strlcpy here. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Sat Mar 31 07:59:16 CEST 2012 on sn-devel-104
* ldb: Permit desactivation of autocomit for every ldb_xxx_ctrl functionMatthieu Patou2012-03-308-23/+28
| | | | | Autobuild-User: Matthieu Patou <mat@samba.org> Autobuild-Date: Fri Mar 30 11:59:09 CEST 2012 on sn-devel-104
* Start to add truncate checks on all uses of strlcpy(). Reading lwnJeremy Allison2012-03-293-24/+35
| | | | | | | has it's uses :-). Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Thu Mar 29 20:48:15 CEST 2012 on sn-devel-104
* lib/tdb: Update ABIAmitay Isaacs2012-03-292-1/+67
| | | | | | | Signed-off-by: Amitay Isaacs <amitay@gmail.com> Autobuild-User: Rusty Russell <rusty@rustcorp.com.au> Autobuild-Date: Thu Mar 29 13:12:46 CEST 2012 on sn-devel-104
* lib/tdb: Add/expose lock functions to support CTDBAmitay Isaacs2012-03-291-2/+16
| | | | | | | | | | | | | | | | | | | This patch adds two lock functions used by CTDB to perform asynchronous locking. These functions do not actually perform any fcntl operations, but only increment internal counters. - tdb_transaction_write_lock_mark() - tdb_transaction_write_lock_unmark() It also exposes two internal functions - tdb_lock_nonblock() - tdb_unlock() These functions are NOT exposed in include/tdb.h to prevent any further uses of these functions. If you ever need to use these functions, consider using tdb2. Signed-off-by: Amitay Isaacs <amitay@gmail.com>
* cast: make sure suncc sees a constant.Rusty Russell2012-03-292-8/+22
| | | | | | | | | | | | | | | | | | cast_const() et. al. are supposed to be a constant expression, so you can do things like: static char *p = cast_const(char *, (const char *)"hello"); Unfortunately, a cast to intptr_t and arithmetic makes suncc reject it as a constant expression. We need the cast, because (1) the expression could be a void *, so we can't just add to it, and (2) gcc complains with -Wcast-qual without it. So instead of adding BUILD_BUG_OR_ZERO, we use a ? :, which keeps everyone happy. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (Imported from CCAN commit 74859ab18b10aaf990848e49d7789ff5c6cf96c6) Autobuild-User: Rusty Russell <rusty@rustcorp.com.au> Autobuild-Date: Thu Mar 29 08:18:57 CEST 2012 on sn-devel-104
* cast: test/compile_fail-cast_static.c should fail without COMPOUND_LITERALS.Rusty Russell2012-03-291-3/+9
| | | | | | | It still gave a warning on gcc, because casting a char to a char* gives a warning. Not so on sun CC. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (Imported from CCAN commit 6569a707d169a629e25e10710c760c8dc84525c7)
* tdb2: fix prototype in tdb1 code.Rusty Russell2012-03-291-5/+5
| | | | | | | | | | We were handing an int-returning function where we should hand an enum TDB_ERROR returning function. Worse, it was returning 0/-1 instead of 0/TDB_ERR_*. Fortunately, it's only compared against success, but the Solaris compiler warns about it, and it's not correct anyway. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* s4 dns: Check smb.conf if we should allow recursionKai Blin2012-03-271-0/+21
|
* LDB/s4 - deny the "(dn=...)" syntax on search filters when in AD modeMatthias Dieter Wallnöfer2012-03-263-2/+19
| | | | | | | Achieve this by introducing a "disallowDNFilter" flag. Reviewed-by: Andrew Bartlett <abartlet@samba.org> Signed-off-by: Andrew Bartlett <abartlet@samba.org>
* replace: Avoid DEBUG(), which is not available in libreplace.Jelmer Vernooij2012-03-251-1/+1
| | | | | Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Sun Mar 25 00:13:59 CET 2012 on sn-devel-104
* libreplace: Add usleep implementation.Jelmer Vernooij2012-03-242-0/+20
|
* lib/util: Remove obsolete sys_getpid() and sys_fork().Jelmer Vernooij2012-03-244-43/+2
| | | | | | | | | The performance of these is minimal (these days) and they can return invalid results when used as part of applications that do not use sys_fork(). Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Sat Mar 24 21:55:41 CET 2012 on sn-devel-104
* lib/util: Allow calloc use in util.c, too.Jelmer Vernooij2012-03-241-0/+1
| | | | | Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Sat Mar 24 18:50:32 CET 2012 on sn-devel-104
* replace: Work around socket wrapper.Jelmer Vernooij2012-03-241-0/+1
| | | | It's fine to ignore socket wrapper here, as it doesn't deal with unix domain sockets.
* replace: Add system/network.h for ucred struct.Jelmer Vernooij2012-03-241-0/+1
|
* libreplace: Add getpeereid implementation.Jelmer Vernooij2012-03-246-31/+71
|
* lib/util: Remove dummy wrapper for getgrgid().Jelmer Vernooij2012-03-242-10/+0
|
* lib/util: Remove dummy wrapper for getgrnam().Jelmer Vernooij2012-03-242-7/+1
|
* lib/util: Remove dummy wrapper for getpwuid().Jelmer Vernooij2012-03-242-8/+2
|
* lib/util: Remove dummy wrapper for getpwnam().Jelmer Vernooij2012-03-242-8/+2
|
* lib/util: Remove dummy wrappers for setpwent/getpwent/endpwent.Jelmer Vernooij2012-03-242-22/+0
|
* lib/util: Move calloc_array and memalign_array to top-level libutil.Jelmer Vernooij2012-03-242-0/+32
|
* lib/util: Remove prototype for removed sys_memalign.Jelmer Vernooij2012-03-241-4/+0
|
* lib/util: Remove trivial wrapper sys_connect() around connect().Jelmer Vernooij2012-03-242-20/+0
|
* replace: Move memalign() from lib/util/system.c to libreplace.Jelmer Vernooij2012-03-245-38/+45
|
* lib/async_req: Retry read_packet with read(2)Volker Lendecke2012-03-231-0/+4
| | | | | | | This way it will also work with pipes Autobuild-User: Volker Lendecke <vl@samba.org> Autobuild-Date: Fri Mar 23 17:31:24 CET 2012 on sn-devel-104
* lib/tdb: fix transaction issue for HAVE_INCOHERENT_MMAP.Rusty Russell2012-03-231-11/+10
| | | | | | | | | | | | | | | | | We unmap the tdb on expand, the remap. But when we have INCOHERENT_MMAP (ie. OpenBSD) and we're inside a transaction, doing the expand can mean we need to read from the database to partially fill a transaction block. This fails, because if mmap is incoherent we never allow accessing the database via read/write. The solution is not to unmap and remap until we've actually written the padding at the end of the file. Reported-by: Amitay Isaacs <amitay@gmail.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Autobuild-User: Rusty Russell <rusty@rustcorp.com.au> Autobuild-Date: Fri Mar 23 02:53:15 CET 2012 on sn-devel-104
* lib/tdb: fix test/run-die-during-transaction when HAVE_INCOHERENT_MMAP.Rusty Russell2012-03-231-0/+5
| | | | | | | | Since we force mmap on, we don't intercept writes to the db, so we never see it in an inconsistent state. #ifdef over the check that we should have recovered it at least once. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* lib/tdb: fix missing return 0 code.Rusty Russell2012-03-231-1/+1
| | | | | | | fde694274e1e5a11d1473695e7ec7a97f95d39e4 made tdb_mmap return an int, but didn't put the return 0 on the "internal db" case. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* lib/tdb2: fix -Wcast-qual warnings.Rusty Russell2012-03-2215-59/+33
| | | | | | | | | | | | | We use tdb_mkdata() to get rid of many of them from the tests, and explicit cast_const() in a few places. tlist_for_each() still causes a warning, but that needs to be fixed in CCAN. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Autobuild-User: Rusty Russell <rusty@rustcorp.com.au> Autobuild-Date: Thu Mar 22 03:29:32 CET 2012 on sn-devel-104
* lib/tdb2: fix -Wshadow warnings.Rusty Russell2012-03-226-27/+27
| | | | | | | | These warnings clutter things up, even though they're of marginal utility. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>