chiark
/
gitweb
/
~ian
/
chiark-tcl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
07bc9fb
)
it made an asynch query
author
ian
<ian>
Thu, 16 Dec 2004 01:07:02 +0000
(
01:07
+0000)
committer
ian
<ian>
Thu, 16 Dec 2004 01:07:02 +0000
(
01:07
+0000)
adns/adns.c
patch
|
blob
|
history
diff --git
a/adns/adns.c
b/adns/adns.c
index 1ecb6729c19b635e343554beec29ee1211fc1c86..3812ffc87d80c30dc6f475619b50d41ef9b07627 100644
(file)
--- a/
adns/adns.c
+++ b/
adns/adns.c
@@
-559,6
+559,7
@@
static void asynch_check(Resolver *res) {
Tcl_Obj *results[RESULTLIST_LLEN];
for (;;) {
Tcl_Obj *results[RESULTLIST_LLEN];
for (;;) {
+ aqu= 0;
ec= adns_check(res->ads, &aqu, &answer, &query_v);
if (ec==ESRCH || ec==EAGAIN) break;
assert(!ec);
ec= adns_check(res->ads, &aqu, &answer, &query_v);
if (ec==ESRCH || ec==EAGAIN) break;
assert(!ec);
@@
-567,7
+568,7
@@
static void asynch_check(Resolver *res) {
query->aqu= 0;
tabledataid_disposing(interp, query, &adnstcl_queries);
query->aqu= 0;
tabledataid_disposing(interp, query, &adnstcl_queries);
- si= (!answer->status ?
si=
&query->on_yes
+ si= (!answer->status ? &query->on_yes
: answer->status > adns_s_max_tempfail ? &query->on_no
: &query->on_fail);
: answer->status > adns_s_max_tempfail ? &query->on_no
: &query->on_fail);
@@
-609,8
+610,8
@@
int do_adns_asynch(ClientData cd, Tcl_Interp *ip,
query->xargs= xargs;
Tcl_IncrRefCount(xargs);
*result= query;
query->xargs= xargs;
Tcl_IncrRefCount(xargs);
*result= query;
-
- r
eturn
TCL_OK;
+ query= 0; /* do not dispose */
+ r
c=
TCL_OK;
x_rc:
if (query) asynch_query_dispose(ip, query);
x_rc:
if (query) asynch_query_dispose(ip, query);