From a2d3f193f511921cacffce83e5e8a6114a0b1d9b Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Thu, 8 Dec 2016 17:59:06 +0000 Subject: [PATCH] Control flow: Introduce adns__intdone_process No functional change. Signed-off-by: Ian Jackson --- src/internal.h | 2 ++ src/query.c | 6 +++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/internal.h b/src/internal.h index 923d43d..007efbd 100644 --- a/src/internal.h +++ b/src/internal.h @@ -720,6 +720,8 @@ void adns__returning(adns_state ads, adns_query qu); * external-faciing functions which call adns__returning should * normally be avoided in internal code. */ +void adns__intdone_process(adns_state ads); + /* From reply.c: */ void adns__procdgram(adns_state ads, const byte *dgram, int len, diff --git a/src/query.c b/src/query.c index a462bbc..438b4fd 100644 --- a/src/query.c +++ b/src/query.c @@ -504,7 +504,7 @@ static void free_query_allocs(adns_query qu) { qu->query_dgram= 0; } -void adns__returning(adns_state ads, adns_query qu_for_caller) { +void adns__intdone_process(adns_state ads) { while (ads->intdone.head) { adns_query iq= ads->intdone.head; adns_query parent= iq->parent; @@ -516,6 +516,10 @@ void adns__returning(adns_state ads, adns_query qu_for_caller) { free(iq->answer); free(iq); } +} + +void adns__returning(adns_state ads, adns_query qu_for_caller) { + adns__intdone_process(ads); adns__consistency(ads,qu_for_caller,cc_entex); } -- 2.30.2