summaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)AuthorFilesLines
2009-08-24note the semantic change in talloc_free from 2.0Andrew Tridgell2-8/+9
2009-08-24fixed typo in talloc doc XMLAndrew Tridgell1-1/+2
2009-08-24LIBREPLACEOBJ now contains the full pathAndrew Tridgell1-4/+1
2009-08-24updated XML source for talloc man pageAndrew Tridgell1-1/+73
2009-08-24added talloc_set_log_* documentationAndrew Tridgell1-0/+11
2009-08-24updated talloc guide for recent API changesAndrew Tridgell1-2/+54
2009-08-24make lib/replace more usable in standalone buildsAndrew Tridgell1-2/+2
This makes the lib/replace m4 work in lib/talloc as a standalone build
2009-08-24fixed getpass m4Andrew Tridgell1-2/+2
This allows the getpass.m4 code to work in standalone talloc builds
2009-08-24talloc: add --enable-talloc-compat1 to build a compat library for talloc 1.x.xStefan Metzmacher5-0/+89
metze
2009-08-24talloc: update talloc.exports and talloc.signaturesStefan Metzmacher2-4/+8
metze
2009-08-24talloc: add defines and functions for TALLOC_MAJOR/MINOR_VERSIONStefan Metzmacher6-11/+72
We also use the major and minor versions in the TALLOC_MAGIC, so that we can detect if two conflicting versions of talloc are loaded in one process. In this case we use talloc_log() to output a very useful debug message before we call talloc_abort(). metze
2009-08-24talloc: change version to 2.0.0Stefan Metzmacher1-1/+1
metze
2009-08-24talloc: remove ABI compat functionsStefan Metzmacher2-31/+0
metze
2009-08-24talloc: remove unused build dependecies to sambaStefan Metzmacher1-18/+0
metze
2009-08-24talloc/testsuite: use talloc_set_log_fn() and log to stdoutStefan Metzmacher1-0/+6
metze
2009-08-24talloc: add talloc_set_log_fn() and talloc_set_log_stderr()Stefan Metzmacher2-12/+51
So that the application can setup a log function to get ERROR and WARNING messages. metze
2009-08-24talloc: let talloc_steal() only generate a warning if it's used with referencesStefan Metzmacher1-2/+1
We have to many callers, which rely on that talloc_steal() never fails. metze
2009-08-24talloc/testsuite: report __location__ of testsuite failuresStefan Metzmacher1-6/+6
metze
2009-08-24talloc/testsuite: add infrastructure to test abortsStefan Metzmacher1-0/+20
metze
2009-08-24talloc/testsuite: reset the globals after each subtestStefan Metzmacher1-3/+29
metze
2009-08-24talloc: call return after abort, because an overloaded abort function might ↵Stefan Metzmacher1-0/+4
not exit This will be useful in the testsuite, where we could check if an abort would happen. metze
2009-08-24talloc: report the size of reference handles as 0Stefan Metzmacher1-1/+3
metze
2009-08-24talloc: let talloc_total_blocks() and talloc_get_size() operate on the ↵Stefan Metzmacher1-2/+15
null_context metze
2009-08-21Fix for bug 6651 - smbd SIGSEGV when breaking oplocks.Jeremy Allison1-17/+54
Based on a patch submitted by Petr Vandrovec <petr@vandrovec.name>. Multiple pending signals with siginfo_t's weren't being handled correctly leading to smbd abort with kernel oplock signals. Jeremy
2009-08-19tevent: fix a commentMichael Adam1-1/+1
Michael
2009-08-17tevent: change version to 0.9.7 after adding tevent_req_cancel infrastructureStefan Metzmacher1-1/+1
metze
2009-08-17tevent: add tevent_req_cancel() infrastructureStefan Metzmacher3-0/+70
This offers a generic way for callers to cancel an async request. metze
2009-08-15tevent: add some more doxygen comments for tevent_req functionsStefan Metzmacher1-0/+38
metze
2009-08-12libreplace: undef AI_ADDRCONFIG on QNX 6.3.0 (fix bug #6630)Matt Kraai1-0/+14
Some of the functions in source3/lib/util_sock.c use AI_ADDRCONFIG. On QNX 6.3.0, this macro is defined but, if it's used, getaddrinfo will fail. This prevents smbd from opening any sockets. If I undefine AI_ADDRCONFIG on such systems and allow lib/replace/system/network.h to define it to be 0, this works around the issue. Signed-off-by: Stefan Metzmacher <metze@samba.org>
2009-08-11Rename ASN1_BITFIELD to ASN1_BIT_STRING.Kouhei Sutou1-1/+1
X.690 uses "BIT STRING" not "BIT FIELD".
2009-08-08libreplace: set SONAMEFLAG to "-Wl,-soname=" on QNXMatt Kraai1-1/+1
2009-08-06Add define guards around otherwise unused variable.Jeremy Allison1-0/+3
Jeremy.
2009-08-06There is one signedness issue in tdb which prevents traverses of TDB recordsRusty Russell1-9/+21
over the 2G offset on systems which support 64 bit file offsets. This fixes that case. On systems with 32 bit offsets, expansion and fcntl locking on these records will fail anyway. SAMBA already does '#define _FILE_OFFSET_BITS 64' in config.h (on my 32-bit x86 Linux system at least) to get 64 bit file offsets. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2009-08-05fixed a uid_wrapper bug that caused a segv in the RAW-ACLS testAndrew Tridgell1-8/+15
2009-08-05make the UID_WRAPPER skip checks at runtimeAndrew Tridgell4-5/+17
This fixes two issues pointed out by Andrew. It adds a runtime uwrap_enabled() call that wraps the skips needed for uid emulation. It also makes the skip in the directory_create_or_exist() function only change the uid checking code, not the permissions code
2009-08-05added a uid_wrapper libraryAndrew Tridgell6-0/+236
This library intercepts seteuid and related calls, and simulates them in a manner similar to the nss_wrapper and socket_wrapper libraries. This allows us to enable the vfs_unixuid NTVFS module in the build farm, which means we are more likely to catch errors in the token manipulation. The simulation is not complete, but it is enough for Samba4 for now. The major areas of incompleteness are: - no emulation of setreuid, setresuid or saved uids. These would be needed for use in Samba3 - no emulation of ruid changing. That would also be needed for Samba3 - no attempt to emulate file ownership changing, so code that (for example) tests whether st.st_uid matches geteuid() needs special handling
2009-07-31util/asn1: fix potential memory leak in asn1_write_OID()Stefan Metzmacher1-0/+1
metze
2009-07-31tdb: don't alter tdb->flags in tdb_reopen_all()Rusty Russell1-6/+13
The flags are user-visible, via tdb_get_flags/add_flags/remove_flags. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Stefan Metzmacher <metze@samba.org>
2009-07-31tdb: Reimplementation of Metze's "lib/tdb: if we know pwrite and pread are ↵Rusty Russell1-5/+10
thread/fork safe tdb_reopen_all() should be a noop". This version just wraps the reopen code, so we still re-grab the lock and do the normal sanity checks. The reason we do this at all is to avoid global fd limits, see: http://forums.fedoraforum.org/showthread.php?t=210393 Note also that this whole reopen concept is fundamentally racy: if the parent goes away before the child calls tdb_reopen_all, the database can be left without an active lock and another TDB_CLEAR_IF_FIRST opener will clear it. A fork_with_tdbs() wrapper could use a pipe to solve this, but it's hardly elegant (what if there are other independent things which have similar needs?). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Stefan Metzmacher <metze@samba.org>
2009-07-31tdb: Revert "lib/tdb: if we know pwrite and pread are thread/fork safe ↵Rusty Russell1-5/+0
tdb_reopen_all() should be a noop" This reverts commit e17df483fbedb81aededdef5fbb6ae1d034bc2dd. tdb_reopen_all also restores the active lock, required for TDB_CLEAR_IF_FIRST. Signed-off-by: Stefan Metzmacher <metze@samba.org>
2009-07-30realloc() has that horrible overloaded free semantic when size is 0:Rusty Russell1-2/+7
current code does a free of the old record in this case, then fail.
2009-07-30If the record is at the end of the database, pretending it has length 1Rusty Russell1-4/+1
might take us out-of-bounds. Only pretend to be length 1 for the malloc.
2009-07-30DCE/RPC(Python): Rename py_talloc_import to py_talloc_steal.Jelmer Vernooij2-7/+8
Use py_talloc_reference in DCE/RPC code, fixes access to SAMR pipe.
2009-07-25No explicit initialization necessary for a zero blobVolker Lendecke1-3/+1
2009-07-21tdb: fix locking errorRusty Russell1-1/+1
54a51839ea65aa788b18fce8de0ae4f9ba63e4e7 "Make tdb transaction lock recursive (samba version)" was broken: I "cleaned it up" and prevented it from ever unlocking. To see the problem: $ bin/tdbtorture -s 1248142523 tdb_brlock failed (fd=3) at offset 8 rw_type=1 lck_type=14 len=1 tdb_transaction_lock: failed to get transaction lock tdb_transaction_start failed: Resource deadlock avoided My testcase relied on the *count* being correct, which it was. Fixing that now. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Michael Adam <obnox@samba.org>
2009-07-20lib util: Fix const warningTim Prouty1-1/+1
2009-07-20Make tdb transaction lock recursive (samba version)Rusty Russell3-21/+20
This patch replaces 6ed27edbcd3ba1893636a8072c8d7a621437daf7 and 1a416ff13ca7786f2e8d24c66addf00883e9cb12, which fixed the bug where traversals inside transactions would release the transaction lock early. This solution is more general, and solves the more minor symptom that nested traversals would also release the transaction lock early. (It was also suggestd in Volker's comment in 6ed27ed). This patch also applies to ctdb, if the traverse.c part is removed (ctdb's tdb code never received the previous two fixes). Tested using the testsuite from ccan (adapted to the samba code). Thanks to Michael Adam for feedback. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Michael Adam <obnox@samba.org>
2009-07-19Remove unused parameter setting.Jelmer Vernooij2-11/+0
2009-07-19lib/util/util_file.c(file_save): fixed file descriptor leak when read(2) fails.Slava Semushin1-0/+1
Found by cppcheck: [./lib/util/util_file.c:383]: (error) Resource leak: fd
2009-07-19Fix broken password quality checkMatthieu Patou2-1/+4
This fixes broken password tests when the passwords contain non ASCII characters (e.g. accentuated chars like ('e, `e, ...)