summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
...
* tests: add new test test_bind_ipv4_addr_in_use()Michael Adam2014-06-011-0/+157
| | | | | | | This tests binding an address that is already in use. Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* tests: extend the ipv6 bind testMichael Adam2014-06-011-0/+23
| | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* tests: greatly extend the ipv4 bind testMichael Adam2014-06-011-0/+88
| | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* tests: Avoid using getenv() to retrieve the path.Andreas Schneider2014-06-011-7/+7
| | | | | | | CID 17221 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* swrap: add check for rpc/rpc.h - needed on freebsd for bindresvportMichael Adam2014-06-011-0/+3
| | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* tests: Add tests for bindresvport().Andreas Schneider2014-05-311-0/+113
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* tests: Add tests for bind().Andreas Schneider2014-05-312-0/+111
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* tests: Add test that getsockname is correct after socket().Andreas Schneider2014-05-312-0/+70
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* torture: Wait for the pidfile and then start the tests.Andreas Schneider2014-05-311-1/+13
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* echo_srv: Write pidfile after we setup the listeners.Andreas Schneider2014-05-311-9/+11
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* tests: Fix possible format string attack.Andreas Schneider2014-05-271-6/+3
| | | | | | | | | | Well, there is really not attack on a test but we want to silence Coverity :) CID 17221 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* tests: Add more tests for socket options.Andreas Schneider2014-05-261-0/+147
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* echo_srv: Add support for IP_SENDSRCADDR.Andreas Schneider2014-05-261-5/+13
| | | | | | 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: 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-261-5/+1
| | | | | | 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-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>
* 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>
* 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>
* 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>
* 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>
* 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>
* 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: Use SOCKET_WRAPPER_LOCATION.Andreas Schneider2014-02-041-2/+2
|
* cmake: Only build test_sendmsg_recvmsg_fd if we have msg_control.Andreas Schneider2014-01-211-2/+5
|
* tests: Add sendmsg_recvmsg_fd test.Jakub Hrozek2014-01-202-1/+118
|
* tests: Add test_echo_udp_sendmsg_recvmsg.Andreas Schneider2014-01-202-1/+201
|
* echo_srv: Add fd duplication and test it works.Andreas Schneider2013-12-241-4/+206
|
* test: Fix getsockopt on Solaris.Andreas Schneider2013-12-231-2/+3
|
* tests: Fix getsockopt() on Solaris.Andreas Schneider2013-12-231-2/+2
|
* tests: writev/readv must have iovec > 0Jakub Hrozek2013-12-231-2/+2
| | | | writev/readv with iovec == 0 works on Linux, but that is not portable.
* tests: Remove unused variable warningJakub Hrozek2013-12-231-0/+2
| | | | The variables were unused if SIOCGPGRP wasn't defined.
* torture: Add TORTURE_SKIP_CLEANUP to not delete socket_dir.Andreas Schneider2013-12-231-4/+9
|
* torture: Generate network traces for each test.Andreas Schneider2013-12-232-0/+13
|
* tests: Add test_echo_tcp_socket_options().Andreas Schneider2013-12-232-0/+152
|
* tests: Add test_echo_tcp_connect test.Andreas Schneider2013-12-232-1/+102
| | | | This tests some corner cases we fixed in the past.
* tests: Add missing include for writev/readv.Andreas Schneider2013-12-211-0/+1
|
* tests: Add an ifdef around static IPv6 only functionsJakub Hrozek2013-12-203-0/+6
| | | | | This would prevent an uninitialized function warning in case IPv6 was not available.
* tests: Add test_echo_tcp_write_readvJakub Hrozek2013-12-202-1/+177
|
* tests: Use torture_server_(address|port).Andreas Schneider2013-12-206-25/+59
| | | | This makes it possible to run tests without socket_wrapper.