Stefan Metzmacher
ee6d796c19
tsocket: add tstream implementation for bsd sockets (inet and unix)
...
metze
2009-05-01 17:41:55 +02:00
Stefan Metzmacher
8a090c4b8b
tsocket: add tstream_context infrastructure similar to tdgram_context
...
metze
2009-05-01 17:41:53 +02:00
Stefan Metzmacher
182a4b30de
tsocket: rename tdgram_unix_dgram_socket() => tdgram_unix_socket()
...
metze
2009-05-01 17:41:38 +02:00
Stefan Metzmacher
b46599590f
tsocket: move tsocket_simple_int_recv() to tsocket.c
...
metze
2009-05-01 17:38:27 +02:00
Stefan Metzmacher
0db3b944bd
tsocket: move tsocket_sendto_queue_send/recv() to tsocket_helpers.c
...
metze
2009-05-01 17:38:26 +02:00
Stefan Metzmacher
b4c5387e9f
tsocket: tdgram move input checks to the common code as there're needed for all backends
...
We need to make sure that we free the sendto and recvfrom requests before
the tdgram_context
metze
2009-05-01 17:38:25 +02:00
Stefan Metzmacher
cc75ff1a37
tsocket: for unix domain sockets we need to use sizeof(struct sockaddr_un)
...
sizeof(struct sockaddr_storage) generates EINVAL.
metze
2009-05-01 17:38:24 +02:00
Stefan Metzmacher
66a2cd36c6
tsocket: return EINVAL when tdgram_sendto_send() is used with len == 0
...
metze
2009-05-01 17:38:23 +02:00
Stefan Metzmacher
997eb9eb43
tsocket: fix dependecies
...
metze
2009-05-01 17:38:22 +02:00
Stefan Metzmacher
9dbb535aa5
tsocket: remove tsocket_context related stuff
...
It will be replaced by tdgram_context and tstream_context.
metze
2009-05-01 17:38:21 +02:00
Volker Lendecke
46bbdbd8c7
Fix a missing prototype warning
2009-04-28 15:34:22 +02:00
Michael Adam
664da577f9
pm_process():raise level of debug message
...
Michael
2009-04-28 12:20:38 +02:00
Jelmer Vernooij
3cf48ee05a
Fix push_codepoint function without iconv_convenience.
2009-04-23 17:50:18 +02:00
Jelmer Vernooij
80420745ff
Add a new non-convenience version of push_codepoint.
2009-04-23 17:50:18 +02:00
Simo Sorce
b029e0edcf
Prevent reallocs of the talloc pool itself
2009-04-22 09:58:06 -04:00
Brad Hards
703d589770
Avoid using deprecated form of AC_CHECK_TYPE.
...
libreplace makes use of an older form of AC_CHECK_TYPE which basically
provides a fallback definition for the type if it isn't available.
http://www.gnu.org/software/hello/manual/autoconf/Obsolete-Macros.html#Obsolete-Macros
shows why this isn't a good idea (its not so important, except for pointer types).
This patch partly addresses the issue.
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>
2009-04-22 10:36:47 +02:00
Jelmer Vernooij
bb0f430064
Error out at runtime when seteuid/setresuid or setegid/setresgid are not
...
available. This means it's possible to compile libreplace when these
functions are not available and use it, as long as this particular
function is not used.
2009-04-20 16:25:17 +02:00
Jelmer Vernooij
20e1ba1c09
Only define waitpid replacement if wait4 is available. (It isn't on
...
Windows.)
2009-04-20 16:25:16 +02:00
Jelmer Vernooij
e5233ccf9e
Cope with the fact that only _mkdir() exists on Windows and that it
...
doesn't take a mode argument.
2009-04-20 16:25:16 +02:00
Jelmer Vernooij
fbf4293d7e
Move check for syslog out of libreplace to source3/ and source4/.
...
This should help compiling talloc on Windows.
2009-04-20 16:25:16 +02:00
Jeremy Allison
5cbd7556c2
Ensure we have all the definitions needed in both threaded and non-threaded versions.
...
Jeremy.
2009-04-20 04:25:26 -07:00
Jeremy Allison
399c765538
Attempt to fix build farm on platforms where pthread_once_t is a struct.
...
Jeremy.
2009-04-20 04:00:06 -07:00
Jeremy Allison
3d2e95c296
Fix the pthread_once initialization issue. Make talloc_stackframe use
...
this.
Jeremy.
2009-04-20 03:04:42 -07:00
Stefan Metzmacher
56aae35a23
tsocket: fix the build without ipv6 support
...
metze
2009-04-16 09:31:14 +02:00
Jeremy Allison
d9804ae3cc
Fix bug #6089 - Winbind samr_OpenDomain not possible with Samba 3.2.6+
...
What a difference a name makes... :-). Just because something is missnamed
SAMR_ACCESS_OPEN_DOMAIN, when it should actually be SAMR_ACCESS_LOOKUP_DOMAIN,
don't automatically use it for a security check in _samr_OpenDomain().
Jeremy.
2009-04-15 15:40:00 -07:00
Jeremy Allison
8e06e945b6
Ensure a tls key is only generated once - wrap create & destroy in a mutex.
...
Change the function names to add _once to the tls_create & tls_destroy to
make this obvious.
Jeremy.
2009-04-14 15:19:39 -07:00
Jeremy Allison
27a3118bcf
Make talloc_stack threadsafe using TLS. Volker please
...
check. Passes make test and basic valgrind testing.
Jeremy.
2009-04-14 12:23:22 -07:00
Stefan Metzmacher
74707e8e8e
socket_wrapper: fix the build on systems without ipv6 support
...
metze
2009-04-14 12:47:18 +02:00
Stefan Metzmacher
f20f5ae8e6
socket_wrapper: fix crash bug in swrap_readv/writev
...
metze
2009-04-10 19:38:29 +02:00
Andrew Tridgell
65ad2ced60
Merge branch 'wspp-schema'
2009-04-09 14:40:19 +10:00
Andrew Tridgell
fd7c52231f
added _const versions of some of the str_list_*() functions
...
These const versions don't copy the strings themselves, which
is useful when those strings point at known constant data (into the
schema in this case)
2009-04-09 14:28:38 +10:00
Andrew Tridgell
4f69d7067d
added str_list_unique() and str_list_show()
...
I also undid some of the const changes from Andrew, as
they didn't in fact resolve the const warnings.
2009-04-09 13:44:27 +10:00
Jeremy Allison
e5702da72c
Add the thread functions to top level lib/util.
...
Not yet used, that's the next step.
Jeremy.
2009-04-08 15:46:49 -07:00
Volker Lendecke
ccd293ba0e
Remove async_req
2009-04-08 23:11:59 +02:00
Andrew Bartlett
54f7523db1
Rework util_strlist prototypes to use a bit more and less const
...
Hopefully this produces less warnings, but it might produce more...
Andrew Bartlett
2009-04-08 23:18:13 +10:00
Karolin Seeger
8da2fa36b4
s3/popt.h: Fix typo.
...
Karolin
2009-04-07 20:05:21 +02:00
Andrew Tridgell
ef6c6ab4c6
added a str_list_append() function
2009-04-07 16:33:26 +10:00
Stefan Metzmacher
522bdea1f3
tsocket: reduce size of dummy variable
...
metze
2009-04-06 16:37:18 +02:00
Stefan Metzmacher
9d9f945281
tsocket: use the correct 'ret' variable for tdgram_disconnect_send/recv()
...
metze
2009-04-06 15:49:08 +02:00
Volker Lendecke
d3825d5d10
Use recv instead of read in read_packet_handler
...
This way the socket wrapper pcap file also sees the replies :-)
2009-04-05 13:45:15 +02:00
Stefan Metzmacher
3bbad34a02
tsocket: remove DGRAM support from tsocket_context
...
metze
2009-04-02 21:54:08 +02:00
Stefan Metzmacher
c59ee5a139
tsocket: optimize tdgram_bsd a lot
...
The desire is to do as less syscalls during the
tdgram_sendto_send/recv() and tdgram_recvfrom_send/recv()
operations.
1. we first try the sendto()/recvfrom() syscall and
only use a fd event if we got EAGAIN.
2. we cache the fd event and only change it's flags
if really needed.
For the highload case we do almost no epoll_ctl() and epoll_wait()/select()
syscalls anymore. This speeds up the LDAP-BENCH-CLDAP test
by more than 20%. (With a modified version of this test
which let the server skip any ldb calls and just return success
I'm getting about 8000 requests per second, while I'm getting
just about 6000 requests per second without optimization)
metze
2009-04-02 21:54:00 +02:00
Stefan Metzmacher
85742dbc06
tsocket: add tdgram_sendto_queue_send/recv()
...
metze
2009-04-02 21:53:59 +02:00
Stefan Metzmacher
8d98070a9f
tsocket: split out a smaller tdgram_context abstraction
...
The idea is to have a tdgram and a tstream abstraction
which only provide tevent_req based io functions.
metze
2009-04-02 21:53:03 +02:00
Stefan Metzmacher
7ce1356c9f
lib/util: fallback to any id in idr_get_new_random()
...
metze
2009-04-01 16:41:15 +02:00
Tim Prouty
42c0931441
tdb: Remove unused variable
2009-03-31 16:24:07 -07:00
Stefan Metzmacher
c200e8632f
tsocket: try to fix the build on solaris FIONREAD was missing
...
metze
2009-03-31 20:33:33 +02:00
Andrew Tridgell
7a5e6940cf
up the version to 1.1.4 with the addition of
...
tdb_transaction_prepare_commit()
2009-03-31 15:06:23 +11:00
Andrew Tridgell
84547b8dba
added basic testing of tdb_transaction_prepare_commit() in tdbtorture
2009-03-31 13:59:03 +11:00
Howard Chu
b90863c0b7
Add tdb_transaction_prepare_commit()
...
Using tdb_transaction_prepare_commit() gives us 2-phase commits. This
allows us to safely commit across multiple tdb databases at once, with
reasonable transaction semantics
Signed-off-by: tridge@samba.org
2009-03-31 13:15:54 +11:00