summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* swrap: Add swrap_sendmsg_filter_cmsg_socket().Andreas Schneider2014-05-261-1/+35
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: Add swrap_sendmsg_copy_cmsg().Andreas Schneider2014-05-261-1/+41
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: Add swrap_sendmsg_filter_cmsghdr().Andreas Schneider2014-05-261-0/+27
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* echo_srv: Implement support for IP_RECVDSTADDR on BSD.Andreas Schneider2014-05-261-14/+52
| | | | | | Pair-Programmed-With: Michael Adam <obnox@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Michael Adam <obnox@samba.org>
* swrap: Implement support for IP_RECVDSTADDR on BSD.Andreas Schneider2014-05-262-6/+23
| | | | | | Pair-Programmed-With: Michael Adam <obnox@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Michael Adam <obnox@samba.org>
* echo_srv: Fix building on OpenIndiana.Andreas Schneider2014-05-261-7/+33
| | | | | | | Solaris doesn't have support for auxillary messages. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: Check if the in_pktinfo structure is available.Andreas Schneider2014-05-264-1/+5
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: Silence a warning on OpenIndiana.Andreas Schneider2014-05-261-0/+2
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* tests: Fix assert_sockaddr_equal() file and line output.Andreas Schneider2014-05-261-1/+2
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* cmake: Add some warnings were we should error out.Andreas Schneider2014-05-261-0/+6
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: Properly cache the handle also in LIBC_SO case.Pino Toscano2014-05-261-0/+2
| | | | | | | | | | Small regression introduced by me in commit 0fa56909442c3cfea6a697681ea0e89ba5a0aa0f. BUG: https://bugzilla.samba.org/show_bug.cgi?id=10572 Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* cmake: Fix a typo in socket_wrapper-config.cmake.in.Andreas Schneider2014-05-221-1/+1
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* cmake: Require cmocka versin 0.4.1.Andreas Schneider2014-05-222-52/+4
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* tests: Add test for different length passed to get(sock|peer)name.Andreas Schneider2014-05-221-0/+58
| | | | | Signed-off-by: Andreas Schneider <asn@cryptomilk.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: Truncate the address if the buffer is to small.Andreas Schneider2014-05-221-2/+14
| | | | | Signed-off-by: Andreas Schneider <asn@cryptomilk.org> Reviewed-by: Michael Adam <obnox@samba.org>
* tests: Add support to sending IP_PKTINFO in echo_srv.Andreas Schneider2014-05-221-3/+88
| | | | | Signed-off-by: Andreas Schneider <asn@cryptomilk.org> Reviewed-by: Michael Adam <obnox@samba.org>
* tests: Add support to receive IP_PKTINFO in echo_srv.Andreas Schneider2014-05-222-5/+195
| | | | | Signed-off-by: Andreas Schneider <asn@cryptomilk.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: Process control messages in recvmsg().Andreas Schneider2014-05-221-1/+40
| | | | | | | Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: Call swrap_msghdr_socket_info in swrap_recvmsg_after().Andreas Schneider2014-05-221-5/+17
| | | | | | | Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: Add swrap_msghdr_socket_info().Andreas Schneider2014-05-221-0/+11
| | | | | | | | Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Pair-Programmed-With: Michael Adam <obnox@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org> Signed-off-by: Michael Adam <obnox@samba.org>
* swrap: Add swrap_msghdr_add_pktinfo().Andreas Schneider2014-05-221-0/+65
| | | | | | | | Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Pair-Programmed-With: Michael Adam <obnox@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org> Signed-off-by: Michael Adam <obnox@samba.org>
* swrap: Add swrap_msghdr_add_cmsghdr().Andreas Schneider2014-05-211-0/+71
| | | | | | | | Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Pair-Programmed-With: Michael Adam <obnox@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org> Signed-off-by: Michael Adam <obnox@samba.org>
* swrap: Add IP_PKTINFO support in setsockopt.Andreas Schneider2014-05-211-0/+21
| | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* cmake: Add check for HAVE_STRUCT_IN6_PKTINFO.Andreas Schneider2014-05-212-0/+9
| | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* cmake: Build swrap with _GNU_SOURCE.Andreas Schneider2014-05-212-1/+7
| | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* tests: Add test to verify that the binded iface address is correct.Andreas Schneider2014-05-082-0/+356
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* swrap: Correctly set the bind iface address on connect().Andreas Schneider2014-05-081-0/+57
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* swrap: use LIBC_SO from GNU libc, if availablePino Toscano2014-05-083-0/+10
| | | | | | | | | Look for gnu/lib-names.h and use the LIBC_SO define to dlopen libc, so the right library is loaded without manually searching for libc.so.N. Signed-off-by: Pino Toscano <toscano.pino@tiscali.it> Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* Bump version to 1.0.2.socket_wrapper-1.0.2Andreas Schneider2014-05-052-2/+7
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* swrap: Fall back to RTLD_NEXT if we can't find libc.Andreas Schneider2014-05-051-4/+4
| | | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=10572 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* Fix some typos.Jakub Wilk2014-05-054-7/+7
| | | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=10566 Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* swrap: Use the loaded libc open() directly.Andreas Schneider2014-04-251-2/+14
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* echo_srv: Fix possible resouce leaks on error in socket_dup().Andreas Schneider2014-04-251-0/+8
| | | | | | | CID: #17217 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* tests: Fix use of tainted string in test_ioctl.Andreas Schneider2014-04-251-1/+6
| | | | | | | CID: #17221 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* cmake: Fix policy check.Andreas Schneider2014-04-251-1/+1
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* cmake: Install cmake config in the correct directory.Andreas Schneider2014-04-251-1/+1
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* echo_srv: Improve reopening low fds.Andreas Schneider2014-04-141-7/+16
| | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org>
* echo_srv: Don't leak client_sock on failures in echo_tcpJakub Hrozek2014-04-141-8/+9
| | | | | | Signed-off-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Simo Sorce <idra@samba.org>
* tests: Fix an out of bound access.Andreas Schneider2014-04-141-2/+4
| | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org>
* tests: Fix a possible resource leak on error in sockopt test.Andreas Schneider2014-04-141-2/+2
| | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org>
* swrap: Do not leak memory in swrap_recvmsg_after().Andreas Schneider2014-04-141-3/+4
| | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org>
* echo_srv: Fix resource leak of fd in pidfile().Andreas Schneider2014-04-141-3/+10
| | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org>
* echo_srv: Fix resource leak of s2 on error.Andreas Schneider2014-04-141-1/+1
| | | | | | | | Found by Coverity. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org>
* echo_srv: Fix resource leak of sock.Andreas Schneider2014-04-141-0/+1
| | | | | | | | Found by Coverity. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org>
* tests: Fix creating remove_cmd.Andreas Schneider2014-04-141-2/+3
| | | | | | | | Found by Coverity. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org>
* tests: Don't leak file description in test_ioctl.Andreas Schneider2014-04-141-0/+2
| | | | | | | | Found by Coverity. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org>
* cmake: Only set policy in cmake 3.0.Andreas Schneider2014-04-101-1/+3
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com>
* cmake: Fix configure warning with cmake 3.0.Andreas Schneider2014-04-071-0/+1
| | | | Signed-off-by: Andreas Schneider <asn@samba.org>
* cmake: Create the compile command database by default.Andreas Schneider2014-04-071-0/+3
| | | | Signed-off-by: Andreas Schneider <asn@samba.org>
* Bump version to 1.0.1.socket_wrapper-1.0.1Andreas Schneider2014-02-042-1/+6
|