summaryrefslogtreecommitdiffstats
path: root/src/tests/cmocka/test_fo_srv.c
Commit message (Collapse)AuthorAgeFilesLines
* tests: Add a regression test for upstream ticket #3131Jakub Hrozek2016-09-221-0/+66
| | | | | | | Tests that running two duplicate SRV resolution queries succeeds and returns a valid host name. Reviewed-by: Pavel Březina <pbrezina@redhat.com>
* FO: Use tevent_req_defer_callback() when notifying callersJakub Hrozek2015-12-071-3/+46
| | | | | | | | | | | | | | If a fo_resolve_service callback would modify the server->common member in any way, for example by dereferencing the server and lowering the refcount to 0, which would free the common structure, then the next iteration of fo_resolve_service_done would access memory that was already gone. Please see https://tevent.samba.org/group__tevent__request.html#ga09373077d0b39e321a196a86bfebf280 for more details. Reviewed-by: Pavel Březina <pbrezina@redhat.com>
* FO: Use refcount to keep track of servers returned to callersJakub Hrozek2015-10-231-10/+16
| | | | | | | Resolves: https://fedorahosted.org/sssd/ticket/2829 Reviewed-by: Pavel Březina <pbrezina@redhat.com>
* tests: Reduce failover code duplicationJakub Hrozek2015-10-231-53/+35
| | | | Reviewed-by: Pavel Březina <pbrezina@redhat.com>
* FO: Also reset the server common data in addition to SRVJakub Hrozek2015-09-231-49/+139
| | | | | | | | | | | In a server that is expanded from a SRV query was reset, only it's 'meta-server' status was set to neutral, but the server->common structure still retained its not_working status. This patch also resets the status of the common structure so that both the SRV query and resolving the server are retried next time. Reviewed-by: Sumit Bose <sbose@redhat.com>
* Resolv: re-read SRV query every time if its TTL is 0Jakub Hrozek2015-03-241-5/+26
| | | | | | | We should make sure the client re-checks the SRV query each request if the SRV query is 0. Reviewed-by: Pavel Březina <pbrezina@redhat.com>
* tests: convert all unit tests to cmocka 1.0 or laterJakub Hrozek2015-03-111-10/+12
| | | | | | All tests now use the cmocka-1.0-compatible API. Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com>
* FO: Use SRV TTL in fail over codeJakub Hrozek2015-03-031-0/+599
Resolves: https://fedorahosted.org/sssd/ticket/1884 Removes the hardcoded SRV TTL timeout and uses TTL from the DNS instead. Reviewed-by: Pavel Březina <pbrezina@redhat.com>