summaryrefslogtreecommitdiffstats
path: root/source3/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* Revert "s3:events: Call all ready fd event handlers on each iteration of the ↵Stefan Metzmacher2011-01-311-15/+7
| | | | | | | | | | main loop" This reverts commit 455fccf86b6544cd17a2571c63a88f8aebff3f74. I'll add a more generic fix for this problem. metze
* s3-rpc_client: remove some more obsolete cli_X.h header files.Günther Deschner2011-01-281-1/+1
| | | | | | | Guenther Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Fri Jan 28 11:18:44 CET 2011 on sn-devel-104
* s3-lib: Fixed a missing return value in tldap.Andreas Schneider2011-01-261-0/+1
| | | | s3-lib: Fixed a missing return value in tldap.
* errormap: Add unix_to_werror() functionKai Blin2011-01-261-0/+6
| | | | | | | | | | | While this function technically is closest to the map_nt_status_from_unix() function, I think it is better to keep the new function in line with our usual fooerror_to_barerror() naming scheme. Signed-off-by: Kai Blin <kai@samba.org> Autobuild-User: Kai Blin <kai@samba.org> Autobuild-Date: Wed Jan 26 23:07:24 CET 2011 on sn-devel-104
* libcli/ldap: use lib/ldb_compat.h for the s3 buildStefan Metzmacher2011-01-241-0/+13
| | | | | | | metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Mon Jan 24 14:55:50 CET 2011 on sn-devel-104
* Revert "s3: Fix an infinite loop"Volker Lendecke2011-01-241-4/+0
| | | | | | | This reverts commit 61f7d7cdeccb1f733590e8bdb8229b32363a815e. Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Mon Jan 24 10:10:43 CET 2011 on sn-devel-104
* s3: Fix an infinite loopVolker Lendecke2011-01-231-0/+4
| | | | | | | | | | | | | | | | | | | | | If select returns EBADF (which should NEVER happen), then we loop infinitely because the select masks seem all active. I've been given an strace where smbd floods syslog with inotify-related error messages. The strace shows that select returns EBADF, and we're calling the inotify event callback. It then complains there's no data on the inotify fd. Metze, please check! We might need to fix this in 3.4 and 3.5 as well. And we need to find the deeper reason where we close a file descriptor and don't tell the events system about it. Volker Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Sun Jan 23 10:05:39 CET 2011 on sn-devel-104
* s3: Fix the code to immediately disconnect from a non-working ctdbdVolker Lendecke2011-01-211-0/+1
|
* s3-libnetapi: prefer dcerpc_srvsvc_X functions.Günther Deschner2011-01-133-15/+86
| | | | | | Guenther Signed-off-by: Andreas Schneider <asn@samba.org>
* s3-libnetapi: prefer dcerpc_netr_X functions.Günther Deschner2011-01-132-13/+32
| | | | | | Guenther Signed-off-by: Andreas Schneider <asn@samba.org>
* s3-libnetapi: add missing error check after switchting to dcerpc_wkssvc_X ↵Günther Deschner2011-01-121-0/+4
| | | | | | functions. Guenther
* s3-initshutdown: prefer dcerpc_initshutdown_X functions.Günther Deschner2011-01-111-3/+9
| | | | Guenther
* s3-wkssvc: prefer dcerpc_wkssvc_X functions.Günther Deschner2011-01-111-6/+21
| | | | Guenther
* s3:lib/netapi: don't set SAMR_FIELD_FULL_NAME if we just want to set the ↵Stefan Metzmacher2010-12-301-3/+0
| | | | | | | | | account name (bug #7896) metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Thu Dec 30 18:09:13 CET 2010 on sn-devel-104
* All calls to event_add_to_select_args() call GetTimeOfDay() andJeremy Allison2010-12-231-6/+5
| | | | | | | | | | | pass this in as the &now parameter. Push this call inside of event_add_to_select_args() to the correct point so it doesn't get called unless needed. Jeremy. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Thu Dec 23 01:08:11 CET 2010 on sn-devel-104
* s3: Remove unused open_any_socket_outVolker Lendecke2010-12-221-165/+0
| | | | | Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Wed Dec 22 17:27:29 CET 2010 on sn-devel-104
* s3:lib/gencache: fix memory leak in error pathStefan Metzmacher2010-12-221-0/+3
| | | | | | | metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Wed Dec 22 15:08:30 CET 2010 on sn-devel-104
* Added call out to a Linux-compatible fallocate() when we need to extend a fileJeremy Allison2010-12-211-0/+35
| | | | | | | allocation extent without changing end-of-file size. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Tue Dec 21 02:41:24 CET 2010 on sn-devel-104
* wb_reqtrans is not used in libwbclientVolker Lendecke2010-12-192-0/+507
|
* s3: FreeBSD has getpeereid(), use itVolker Lendecke2010-12-191-0/+4
|
* s3: Fix some typosVolker Lendecke2010-12-191-1/+1
|
* s3: Fix serverid_existsVolker Lendecke2010-12-191-0/+4
| | | | | | | In the cluster case it can happen that a node just died and we did not yet have the time to clean up serverid.tdb. If the corresponding serverid.tdb record that represented a process was migrated away from the dead record, it represents existence of a process where it is already dead.
* Fix read/write calls over sockets to cope with EAGAIN/EWOULDBLOCK for ↵Jeremy Allison2010-12-152-16/+68
| | | | non-blocking sockets.
* s3: Add gencache_iterate_blobsVolker Lendecke2010-11-281-57/+87
|
* s3: Convert gencache_get_data_blob to gencache_parseVolker Lendecke2010-11-281-59/+38
|
* s3: Add gencache_parseVolker Lendecke2010-11-281-0/+59
|
* s3-libnetapi Load case tables earlierAndrew Bartlett2010-11-241-2/+3
| | | | | | | | | | If we don't load the case tables as the 'first' thing we do, we will segfault on the first case insensitive string comparison. Andrew Bartlett Autobuild-User: Andrew Bartlett <abartlet@samba.org> Autobuild-Date: Wed Nov 24 09:21:05 CET 2010 on sn-devel-104
* s3-libnetapi Add function header commentsAndrew Bartlett2010-11-241-0/+3
| | | | Andrew Bartlett
* s3-netapi Add libnetapi_net_init(), don't double-init common Samba subsystemsAndrew Bartlett2010-11-243-12/+60
| | | | | | | | | | | | | The issue here is that libnet and net were both trying to load the smb.conf files, the case tables and set the debug levels. The set of the debug levels caused problems, because it would force the level to 0, not (say) 10 as requested on the command line. This regression was apparently introduced in cf4de8ec2c8df2ceabbe3d836d296b058e7b19fb when eliminating AllowDebugChange. Andrew Bartlett
* Move error reporting of messaging context creation fail intoJeremy Allison2010-11-143-6/+3
| | | | | | | | the daemons themselves. Allows client utilities to silently fail to create a messaging context due to access denied on the messaging tdb (which I need for the following patch). Jeremy.
* Fix bug 7781 - Samba transforms ShareName to lowercase (sharename) when ↵Jeremy Allison2010-11-102-1/+5
| | | | | | | | | adding new share via MMC Change the find_service() interface to not depend on fstring, and create a useable talloc-based interface. Jeremy.
* s3:util_str: add strlen_m_ext_term() - variant of strlen_m_ext() counting ↵Michael Adam2010-11-031-0/+9
| | | | terminator
* s3:lib/util_str: add strlen_m_ext() that takes input and output charsetMichael Adam2010-11-031-13/+55
| | | | | | | The function calculates the number of units (8 or 16-bit, depending on the destination charset), that would be needed to convert the input string which is expected to be in in src_charset encoding to the dst_charset (which should be a unicode charset).
* s3:lib/util_str: clarify the comment header for strlen_m().Michael Adam2010-11-031-4/+6
|
* s3:lib/charcnv: clarify comments in next_codepoint_ext()Michael Adam2010-11-031-2/+2
| | | | | (giving the unicod U+<hexnumber> notation of the codepoints referred to in the comments)
* s3:lib/charcnv: rename a parameter for clarity in next_codepoint_ext()Michael Adam2010-11-031-5/+5
|
* s3:lib/charcnv: reformat comments in next_codepoint_ext()Michael Adam2010-11-031-12/+18
|
* s3:lib/charcnv: add next_codepoint_ext() that accepts input charset.Michael Adam2010-11-031-11/+32
| | | | | | | | | | next_codepoint() takes as string in CH_UNIX encoding and returns the unicode codepoint of the next (possibly multibyte) character of the input string. The new next_codepoint_ext() function adds the encoding of the input string as a parameter. next_codepoint() now only calls next_codepoint_ext() with CH_UNIX als src_charset argument.
* s3: Do not connect to ctdb if it is blocked for some reasonVolker Lendecke2010-11-021-0/+58
|
* cluster_fatal() exit code should not indicate success.Martin Schwenke2010-11-021-1/+1
| | | | | | | | | | cluster_fatal() logs a fatal event and then exits with 0. This seems wrong. Sometimes command like "net" use this code and return incorrect empty output but then exit with 0. This simply changes the exit code to 1. Signed-off-by: Martin Schwenke <martin@meltin.net>
* s3-libsmbclient Add comments to describe the behaviour of DEBUG()Andrew Bartlett2010-11-021-0/+5
| | | | | | | | | | | | | This isn't quite what you would expect from this interface, but actually avoids some really nasty situations if you ever have more than one libsmbclient context in a process. In the real world, if you have asked for DEBUG() to stderr in one part of the code, you will want it globally, even in a different thread (which in the past would have rest everything to stdout again, at least while starting up). Andrew Bartlett
* debug Explain the behaviour of setup_logging() more clearlyAndrew Bartlett2010-11-021-0/+6
|
* s3-debug Clarify the handling of invalid state.fd values in debug.cAndrew Bartlett2010-11-021-9/+10
| | | | | | | This makes it clear that -1 and 0 are both invalid file descriptor values for DEBUG output. Andrew Bartlett
* s3-debug Convert from x_file to real file descriptors.Andrew Bartlett2010-11-021-47/+31
| | | | | | | | | | X_FILE does not gain us anything in this use case, we want our log messages on disk, not in a buffer, and we don't gain anything from the X_FILE api. I discussed the matter with tridge, who feels that to use FILE in the first place was a mistake, and that X_FILE isn't any better, but was a stop-gap to avoid issues on solaris. Andrew Bartlett
* s3-debug Remove 'AllowDebugChange' and use lp_set_cmdline() insteadAndrew Bartlett2010-11-023-18/+3
| | | | | | | | | By removing this global variable, the API between the two different debug systems is made more similar. Both s3 and s4 now have lp_set_cmdline() which ensures that the smb.conf cannot overwrite these the user-specified log level. Andrew Bartlett
* s3-debug Impove setup_logging() to specify logging to stderrAndrew Bartlett2010-11-023-79/+92
| | | | | | | | This change improves the setup_logging() API so that callers which wish to set up logging to stderr can simply ask for it, rather than directly modify the dbf global variable. Andrew Bartlett
* s3: Pass tdb_flags to ctdbd when attaching to a dbVolker Lendecke2010-10-261-1/+1
| | | | This is required to make ctdb create databases with INCOMPATIBLE_HASH
* s3: Add any_nt_status_not_okVolker Lendecke2010-10-201-0/+13
| | | | | This helps avoid quite a bit of repetitive code when looking at dcerpc_xx_recv results.
* Make getpwnam_alloc() static to lib/username.c, and ensure all username ↵Jeremy Allison2010-10-203-90/+74
| | | | | | | | | | | | lookups go through Get_Pwnam_alloc(), which is the correct wrapper function. We were using it *some* of the time anyway, so this just makes us properly consistent. Jeremy. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Wed Oct 20 16:02:12 UTC 2010 on sn-devel-104
* libcli/auth Merge source4/libcli/security and util_sid.c into the common codeAndrew Bartlett2010-10-141-313/+1
| | | | | | | | | This should ensure we only have one copy of these core functions in the tree. Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>