summaryrefslogtreecommitdiffstats
path: root/lib/util
Commit message (Collapse)AuthorAgeFilesLines
* Revert "s4:remove "util_ldb" submodule and integrate the three gendb_* calls ↵Matthias Dieter Wallnöfer2010-10-173-0/+148
| | | | | | | | | | | | in "dsdb/common/util.c"" This reverts commit 8a2ce5c47cee499f90b125ebde83de5f9f1a9aa0. Jelmer pointed out that these are also in use by other LDB databases - not only SAMDB ones. Autobuild-User: Matthias Dieter Wallnöfer <mdw@samba.org> Autobuild-Date: Sun Oct 17 13:37:16 UTC 2010 on sn-devel-104
* s4:remove "util_ldb" submodule and integrate the three gendb_* calls in ↵Matthias Dieter Wallnöfer2010-10-173-150/+0
| | | | | | | | | "dsdb/common/util.c" They're only in use by SAMDB code. Autobuild-User: Matthias Dieter Wallnöfer <mdw@samba.org> Autobuild-Date: Sun Oct 17 09:40:13 UTC 2010 on sn-devel-104
* s4:lib/util/util_ldb.c - remove unused "gendb_add_ldif" callMatthias Dieter Wallnöfer2010-10-171-17/+0
|
* s4:"wrap_casefold" - move it to "ldb_wrap.c" since it's only used thereMatthias Dieter Wallnöfer2010-10-171-5/+0
|
* lib/debug Add DEBUGC and DEBUGADDC as dummiesAndrew Bartlett2010-10-121-0/+4
| | | | | | | This allows code that needs to also compile against the source3 debug code to compile in source4. Andrew Bartlett
* util: Fix installation path of tevent_ntstatus.h, tevent_unix.h (bug 7720).Jelmer Vernooij2010-10-111-0/+1
| | | | | Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Mon Oct 11 09:24:56 UTC 2010 on sn-devel-104
* util: Link headers to correct subsystem, fix formatting.Jelmer Vernooij2010-10-101-12/+12
|
* idtree: fix right shift of signed ints, crash on large ids on AIXRusty Russell2010-10-061-1/+1
| | | | | | | | | | | | | | | | | Right-shifting signed integers in undefined; indeed it seems that on AIX with their compiler, doing a 30-bit shift on (INT_MAX-200) gives 0, not 1 as we might expect. The obvious fix is to make id and oid unsigned: l (level count) is also logically unsigned. (Note: Samba doesn't generally get to ids > 1 billion, but ctdb does) Reported-by: Chris Cowan <cc@us.ibm.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Autobuild-User: Rusty Russell <rusty@samba.org> Autobuild-Date: Wed Oct 6 08:31:09 UTC 2010 on sn-devel-104
* lib/util/asn1: let asn1_peek_full_tag() return an error if we fail to parse ↵Stefan Metzmacher2010-10-041-1/+13
| | | | | | | | | tag hdr/len metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Mon Oct 4 14:46:40 UTC 2010 on sn-devel-104
* s3: Fix a 64-bit BUGVolker Lendecke2010-10-021-1/+1
| | | | | | | | | | | | | | | Quick explanation why this is a problem: It is not safe to pass a pointer to a uint32_t into a routine that expects a size_t *. The routine that this pointer is passed to has no chance to find out that in reality it was passed a pointer to a uint32_t. On platforms where sizeof(size_t)==8, we get a nice overwrite of a stack area that should not be overwritten. As this happens over an over again: Does someone know a means to make gcc stop with an error in this case? Volker
* samba: share select wrappers.Günther Deschner2010-10-014-2/+242
| | | | Guenther
* util: added BINARY_ARRAY_SEARCH_V()Andrew Tridgell2010-09-291-0/+16
| | | | this is used to search an array of values
* Remove talloc_autofree_context() from pm_processVolker Lendecke2010-09-271-1/+1
| | | | | This would be a classic for talloc_tos(), InFile is freed a few lines down. But unfortunately S4 does not support talloc_tos().
* Lift talloc_autofree_context() from OpenConfFile()Volker Lendecke2010-09-271-3/+3
|
* lib/util: change tevent_req_nterror() to a macroStefan Metzmacher2010-09-272-3/+10
| | | | | | | | | | This way we can record where a tevent_req was finished by tevent_req_nterror(). metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Mon Sep 27 03:18:14 UTC 2010 on sn-devel-104
* lib/util/asn1: add asn1_peek_tag_needed_size() and asn1_peek_full_tag()Stefan Metzmacher2010-09-262-0/+85
| | | | | | | We need a way to ask for the length of a tag without having the full buffer yet. metze
* strlist: Make test names unique.Jelmer Vernooij2010-09-211-2/+8
|
* tevent: include libreplace heade before tevent headerBjörn Jacke2010-09-211-1/+1
| | | | this is supposed to fix bug #7463. Thanks to Joachim Schmitz.
* s3: Fix the charset_pull routine (bug 7531)Volker Lendecke2010-09-191-1/+1
| | | | In the push routine we do the SVAL, so we should do the SSVAL here.
* lib/util: usec_time_diff takes arguments the other way round than TvalDiff didBjörn Jacke2010-09-171-1/+1
|
* s3/s4: merge msleep and smb_msleepBjörn Jacke2010-09-162-8/+43
| | | | | the merged variant is renamed to smb_msleep as some platforms already have a msleep function.
* Fix a typoVolker Lendecke2010-09-151-1/+1
|
* Ensure incoming timespec values correctly wrap at nsecs.Jeremy Allison2010-09-141-0/+7
| | | | Jeremy.
* lib/util: remove some unused_result warnings.Günther Deschner2010-09-091-2/+7
| | | | Guenther
* lib/util: add time_mono() for monotonic time a la time()Björn Jacke2010-09-072-0/+26
|
* util: added samba_start_debugger()Andrew Tridgell2010-09-042-0/+18
| | | | | This developer function is useful for debugging unusual error conditions
* lib/util: add nsec_time_diff to calulate diffs from timespecsBjörn Jacke2010-08-312-0/+14
|
* lib/util: add function to query the monotonic clock with the required ↵Björn Jacke2010-08-312-0/+15
| | | | fallback to the realtime clock
* libreplace: move gettimeofday TZ arg check hereBjörn Jacke2010-08-311-9/+0
|
* lib/util: remove implicit discard_const_p() from SAFE_FREE()Stefan Metzmacher2010-08-281-1/+1
| | | | | | | | This should fix a lot of warnings on IRIX. If callers know what they're doing they can use discard_const_p() on their own. metze
* s3: Fix a ton of type-punned warningsVolker Lendecke2010-08-171-4/+4
|
* lib: added samba-util.pc creationAndrew Tridgell2010-07-262-1/+13
| | | | Thanks to Brad Hards for this patch
* s4-loadparm: 2nd half of lp_ to lpcfg_ conversionAndrew Tridgell2010-07-162-7/+7
| | | | | | | this converts all callers that use the Samba4 loadparm lp_ calling convention to use the lpcfg_ prefix. Signed-off-by: Andrew Bartlett <abartlet@samba.org>
* Move UCS2 macros to common codeJelmer Vernooij2010-06-251-0/+23
|
* librpc: Install the right headers.Jelmer Vernooij2010-06-131-1/+1
|
* Since idtree assigns sequentially, it rarely reaches high numbers.Rusty Russell2010-06-101-3/+5
| | | | | | | | | But such numbers can be forced with idr_get_new_above(), and that reveals two bugs: 1) Crash in sub_remove() caused by pa array being too short. 2) Shift by more than 32 in _idr_find(), which is undefined, causing the "outside the current tree" optimization to misfire and return NULL.
* Change data_blob() to be based on top of data_blob_talloc(), instead of the ↵Jeremy Allison2010-05-181-15/+10
| | | | | | | | | | | | reverse (as it is now). It makes no sense to talloc off the null context, then talloc steal into the required context - just talloc off the correct context, and change data_blob() to pass in the null context to data_blob_talloc(). Jeremy. Signed-off-by: Günther Deschner <gd@samba.org>
* lib/util: fix waf configure tests for xattr functions on Mac OS 10.Stefan Metzmacher2010-05-141-4/+6
| | | | metze
* Install util/tevent_* public headers. Required by OpenChange for compiling IDLJulien Kerihuel2010-05-122-1/+3
| | | | Signed-off-by: Stefan Metzmacher <metze@samba.org>
* util-runcmd: ignore spurious ECHILD errorsAndrew Tridgell2010-04-201-0/+14
| | | | | | | | | | when we get ECHILD in samba_runcmd it is because the parent has set SIGCHLD to SIG_IGN. In that case the child status information is lost. We then have to fallback on the logging of child error messages for any useful information on what happened to the child. A longer term fix is to stop using SIG_IGN for SIGCHLD in the standard process model of s4.
* runcmd: use tevent_re_initialise() to close socketsAndrew Tridgell2010-04-191-0/+4
| | | | this ensures that all event fds are closed in the child
* libreplace: added _PUBLIC_ and _PRIVATE_ to replace.hAndrew Tridgell2010-04-181-6/+0
| | | | | these are needed for all libs that use ABI checking, so libreplace is the logical place for now
* s4-waf: inline LIBREPLACE_NETWORK into 'replace'Stefan Metzmacher2010-04-121-1/+1
| | | | metze
* build: allow the waf build to work with python 3.0 and 3.1Thomas Nagy2010-04-081-1/+1
| | | | | | Python 3.x is a bit fussier about print statements and indentation. Signed-off-by: Andrew Tridgell <tridge@samba.org>
* s4-waf: removed the AUTOGENERATED markersAndrew Tridgell2010-04-061-3/+0
| | | | we won't be using the mk -> wscript generator again
* s4-waf: more dependencies on tallocAndrew Tridgell2010-04-061-4/+5
| | | | | these are needed so we can support a system talloc without using the bundled talloc.h
* s4-waf: fixed some deps now we don't auto-include tevent and replaceAndrew Tridgell2010-04-061-1/+1
| | | | | this is preparation for being able to use system versions of these libraries
* s4-waf: mark the wscript files as python so vim/emacs knows how to highlight ↵Andrew Tridgell2010-04-064-0/+8
| | | | them
* s4-waf: install the rest of the headersAndrew Tridgell2010-04-061-3/+4
|
* s4-waf: started adding auto-install of include filesAndrew Tridgell2010-04-061-1/+2
|