summaryrefslogtreecommitdiff
path: root/source3/lib
AgeCommit message (Collapse)AuthorFilesLines
2011-06-06s3-lib Remove unused lib_path()Andrew Bartlett1-13/+0
2011-06-04Add the same fix to the S3 event backend as the previous commit added to the ↵Jeremy Allison1-1/+14
tevent poll backend. Metze please check ! Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Sat Jun 4 00:27:37 CEST 2011 on sn-devel-104
2011-06-01Revert "s3: Mark sockets in error state writable"Volker Lendecke1-23/+0
This reverts commit 5f6f71956460d6840c1433b59e20555268b622ac. Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Wed Jun 1 14:56:25 CEST 2011 on sn-devel-104
2011-06-01lib/util/time.c: timeval_current_ofs_usecRusty Russell1-7/+7
Several places want "microseconds from current time", and several were simply handing "usecs" values which could be over a million. Using a helper to do this is safer and more readable. I didn't replace any obviously correct callers (ie. constants). I also renamed wait_nsec in source3/lib/util_sock.c; it's actually microseconds not nanoseconds (introduced with this code in Volker's 19b783cc Async wrapper for open_socket_out_send/recv). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2011-06-01Change sys_getcd() to take no arguments and always return malloc'ed memory ↵Jeremy Allison1-7/+34
(or NULL). Part of the efforts to remove PATH_MAX on modern systems.
2011-06-01s3: fix more -Wunused-but-set-variable build warnings.Günther Deschner1-3/+0
Guenther Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Wed Jun 1 00:29:30 CEST 2011 on sn-devel-104
2011-05-31s3: Mark sockets in error state writableVolker Lendecke1-0/+23
Without this patch, when a socket only has a write event pending, we will never detect an error condition. I've seen winbind doing 12:19:13.659964 gettimeofday({1306837153, 659984}, NULL) = 0 <0.000016> 12:19:13.660109 poll([{fd=35, events=POLLOUT}, {fd=32, events=POLLIN|POLLHUP}], 2, 9996) = 1 ([{fd=35, revents=POLLERR|POLLHUP}]) <0.000015> 12:19:13.660253 gettimeofday({1306837153, 660269}, NULL) = 0 <0.000013> 12:19:13.660298 poll([{fd=35, events=POLLOUT}, {fd=32, events=POLLIN|POLLHUP}], 2, 9996) = 1 ([{fd=35, revents=POLLERR|POLLHUP}]) <0.000015> for a while when trying to connect to a DC when the socket had died already. Volker Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Tue May 31 20:59:10 CEST 2011 on sn-devel-104
2011-05-31s3: add _LIB_IDMAP_CACHE_H_ guard to lib/idmap_cache.hMichael Adam1-0/+5
2011-05-31s3: add GPL/Copyright header to lib/idmap_cache.hMichael Adam1-0/+20
2011-05-31s3:lib/eventlog/proto.h: add _LIB_EVENTLOG_PROTO_H_ guardMichael Adam1-0/+5
2011-05-31s3:lib/eventlog/proto.h: add GPL/Copyright headerMichael Adam1-0/+22
2011-05-31s3-lib Move source3-specific malloc replacements into a seperate fileAndrew Bartlett2-143/+171
This will make it easier to create a dep tree for otherwise simple libraries. Andrew Bartlett
2011-05-31lib/util Move sys_memalign into lib/util/system.cAndrew Bartlett1-36/+0
2011-05-31s3-lib Improve indentation of errmap_unixAndrew Bartlett1-36/+36
This also makes it easier to compare and contrast with the source4 version, because the differences here matter, and need to be resolved with care. Andrew Bartlett
2011-05-31s3-lib: Use ARRAY_SIZE() to walk the error mapping tablesAndrew Bartlett1-6/+4
This gives a constant termination condition, and may help the compiler. Andrew Bartlett
2011-05-31s3-build Specify more of the smbconf dependenciesAndrew Bartlett2-163/+162
This brings more functions into util_names.c, and util_names.c into PARAM_WITHOUT_REG_SRC. This is not yet a full list, that would formalise the implicit dependency loop. Andrew Bartlett Autobuild-User: Andrew Bartlett <abartlet@samba.org> Autobuild-Date: Tue May 31 01:43:37 CEST 2011 on sn-devel-104
2011-05-31s3-build Create dbwrap_util subsystemAndrew Bartlett2-61/+64
This contains the functions from dbwrap that don't require lp_ functions, and can therefore be put into a library (without dependency loops). Andrew Bartlett
2011-05-31s3-lib Move free_namearray() into it's own fileAndrew Bartlett2-16/+39
This makes it easier to have conn_smbd strictly depend on all it's dependencies. Andrew Bartlett
2011-05-31s3-lib Move realloc based string substitution functions out of util_str.cAndrew Bartlett3-123/+148
This makes the dependency set for source3/lib/util_str.c simpiler, which in turn makes it easier to build a dependency tree. Andrew Bartlett
2011-05-31s3-lib Move sstring_sub() to it's only user and make staticAndrew Bartlett1-27/+0
This should not be used more generally, as it is specifically not for multibyte strings, and uses malloc rather than talloc. Andrew Bartlett
2011-05-31s3-param Move init_iconv() to loadparm.cAndrew Bartlett1-14/+0
This assists with some dependency loops Andrew Bartlett
2011-05-31libcli/security: move secdesc.c to the top level libcli/securityAndrew Bartlett1-712/+0
This code does not rely on lp_ or other source3 only functions, so can be part of the common library. Andrew Bartlett
2011-05-31s3-globals Remove smbd_event_context() (use server_event_context())Andrew Bartlett1-5/+0
This has been a wrapper around server_event_context() for some time now, and removing this from dummmysmbd.c assists with library dependencies. Andrew Bartlett
2011-05-31s3-param split service.c into param and smbd componentsAndrew Bartlett2-11/+35
The dependency chain of find_service can't be satisfied sensibly outside smbd, so don't include this in the main 'param' subsystem. Also remove the duplicate find_service() and conn_snum_used() from dummysmbd.c: The WAF build does not need these dummies any more, but file. Andrew Bartlett
2011-05-31s3-lib Move string_init functions into their own fileAndrew Bartlett2-52/+77
These have not been moved in common, as they are not talloc-based, but it helps with dependencies if these are seperated from the rest of util_str.c Andrew Bartlett
2011-05-31s3-smbd provide struct smbd_server_connection * to conn_snum_usedAndrew Bartlett1-1/+2
This provides the 'sconn' parameter to this key functions, that is currently duplicated in dummysmbd.c, which causes duplicate symbol issues in the waf build. This has natrually caused a number of consequential changes across the codebase, includning not passing a messaging context into initial reload_services(): This causes problems because the global smbd_server_connection isn't yet set up, as there isn't a connection here, just the initial process. Andrew Bartlett
2011-05-30s3: fix some -Wunused-but-set-variable build warnings.Günther Deschner1-2/+0
Guenther Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Mon May 30 17:41:18 CEST 2011 on sn-devel-104
2011-05-20s3: Fix Coverity ID 2573: UNUSED_VALUEVolker Lendecke1-2/+3
Andrew B., please check!
2011-05-19Fix Bug 8152 - smbd crash in release_ip()Christian Ambach1-0/+5
release_ip() needs the private_data, but it was never saved away to feed it into release_ip() later Autobuild-User: Christian Ambach <ambi@samba.org> Autobuild-Date: Thu May 19 21:21:14 CEST 2011 on sn-devel-104
2011-05-18s3-lib Replace StrnCaseCmp() with strncasecmp_m()Andrew Bartlett3-63/+3
strncasecmp_m() never needs to call to talloc, and via next_codepoint() still has an ASCII fast-path bypassing iconv() calls. Andrew Bartlett
2011-05-18s3-lib Replace StrCaseCmp() with strcasecmp_m()Andrew Bartlett7-93/+10
strcasecmp_m() never needs to call to talloc, and via next_codepoint() still has an ASCII fast-path bypassing iconv() calls. Andrew Bartlett
2011-05-17is_my_ipaddr() should recognise loopback addresses as ours.Jeremy Allison1-5/+5
Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Tue May 17 20:05:42 CEST 2011 on sn-devel-104
2011-05-13s3-netapi Initialise global variables in libnetapiAndrew Bartlett1-1/+1
It is important to initalise the global variables when loading this configuration for the potentially first time. Andrew Bartlett
2011-05-13s3-libnetapi Don't create a talloc_stackframe() in a global variableAndrew Bartlett2-16/+37
This also ensures that libnetapi_free() invalidates the global stat_ctx variable, and changes the API so that the behaviour of the error string routines is to consistently return a allocated string. Pair-Programmed-With: Günther Deschner <gd@samba.org> Andrew Bartlett
2011-05-13s3-libnetapi/libnetjoin: fix uninitialized variables after the libsmbconf ↵Günther Deschner1-1/+1
changes. Guenther
2011-05-12s3-lib/smbconf: fix uninitialized error code in smbconf_reg_init().Günther Deschner1-1/+1
Guenther Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Thu May 12 18:09:16 CEST 2011 on sn-devel-104
2011-05-10libsmbconf: Convert smbconf_transaction_*() to sbcErr.Andreas Schneider1-6/+27
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_delete_includes() to sbcErr.Andreas Schneider2-13/+16
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_set_includes() to sbcErr.Andreas Schneider2-18/+23
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_get_includes() to sbcErr.Andreas Schneider2-19/+18
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_delete_parameter() to sbcErr.Andreas Schneider1-6/+8
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_get_parameter() to sbcErr.Andreas Schneider1-7/+6
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_set_parameter() to sbcErr.Andreas Schneider2-13/+22
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_delete_share() to sbcErr.Andreas Schneider1-7/+14
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_get_share() to sbcErr.Andreas Schneider1-56/+73
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_create_share() to smbErr.Andreas Schneider1-10/+12
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_get_share_names() to sbcErr.Andreas Schneider1-29/+37
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_drop() to sbcErr.Andreas Schneider1-6/+12
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_open() to sbcErr.Andreas Schneider2-12/+16
Signed-off-by: Michael Adam <obnox@samba.org>
2011-05-10libsmbconf: Convert smbconf_init() to sbcErr.Andreas Schneider6-21/+28
Signed-off-by: Michael Adam <obnox@samba.org>