[asterisk-commits] mmichelson: branch group/dns r432718 - /team/group/dns/tests/
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Tue Mar 10 14:29:08 CDT 2015
Author: mmichelson
Date: Tue Mar 10 14:29:07 2015
New Revision: 432718
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=432718
Log:
Add an extra expected completed query in cancellation test.
Test now passes, but I still have a FRACK from the scheduler.
Modified:
team/group/dns/tests/test_dns_recurring.c
Modified: team/group/dns/tests/test_dns_recurring.c
URL: http://svnview.digium.com/svn/asterisk/team/group/dns/tests/test_dns_recurring.c?view=diff&rev=432718&r1=432717&r2=432718
==============================================================================
--- team/group/dns/tests/test_dns_recurring.c (original)
+++ team/group/dns/tests/test_dns_recurring.c Tue Mar 10 14:29:07 2015
@@ -549,7 +549,15 @@
goto cleanup;
}
- /* Query has been canceled. Now wait to make sure there are no more recurring queries */
+ /* Query has been canceled. We'll be told that the query in flight has completed */
+ ast_mutex_lock(&rdata->lock);
+ while (!rdata->query_complete) {
+ ast_cond_wait(&rdata->cond, &rdata->lock);
+ }
+ rdata->query_complete = 0;
+ ast_mutex_unlock(&rdata->lock);
+
+ /* Now ensure that no more queries get completed after cancellation */
clock_gettime(CLOCK_REALTIME, &timeout);
timeout.tv_sec += 10;
More information about the asterisk-commits
mailing list