chiark / gitweb /
Support and test iteration; test return in different order.
authorian <ian>
Wed, 14 Jul 1999 22:45:01 +0000 (22:45 +0000)
committerian <ian>
Wed, 14 Jul 1999 22:45:01 +0000 (22:45 +0000)
17 files changed:
client/adnstest.c
regress/case-ndots-as.err [new file with mode: 0644]
regress/case-ndots-as.out [new file with mode: 0644]
regress/case-ndots-as.sys [new file with mode: 0644]
regress/case-ndots.sys
regress/case-rootqueryall-as.err [new file with mode: 0644]
regress/case-rootqueryall-as.out [new file with mode: 0644]
regress/case-rootqueryall-as.sys [new file with mode: 0644]
regress/case-rootqueryall.sys
regress/case-search-as.err [new file with mode: 0644]
regress/case-search-as.out [new file with mode: 0644]
regress/case-search-as.sys [new file with mode: 0644]
regress/case-search.sys
src/adns.h
src/event.c
src/internal.h
src/setup.c

index eb9dccfa1d95dcd0170bf0a1be0d2df6d2bec29f..cbb896a2a5b5b39afe25162ddd1e353506e172b6 100644 (file)
@@ -138,7 +138,7 @@ int main(int argc, char *const *argv) {
   initflagsnum= strtoul(initflags,&ep,0);
   if (*ep == ',') {
     owninitflags= ep+1;
-    if (!consistsof(owninitflags,"p")) {
+    if (!consistsof(owninitflags,"ps")) {
       fputs("unknown owninitflag\n",stderr);
       exit(4);
     }
@@ -162,6 +162,7 @@ int main(int argc, char *const *argv) {
                "              [ :<typenum>,... ]\n"
                "              [ [<queryflagsnum>[,<ownqueryflags>]/]<domain> ... ]\n"
                "initflags:   p  use poll(2) instead of select(2)\n"
+               "             s  use adns_wait with specified query, instead of 0\n"
                "queryflags:  a  print status abbrevs instead of strings\n",
                stderr);
          exit(4);
@@ -252,8 +253,13 @@ int main(int argc, char *const *argv) {
     }
     if (!mcw) break;
 
-    mc= mcw;
-    qu= mcw->qu;
+    if (strchr(owninitflags,'s')) {
+      qu= mcw->qu;
+      mc= mcw;
+    } else {
+      qu= 0;
+      mc= 0;
+    }
 
     if (strchr(owninitflags,'p')) {
       for (;;) {
@@ -278,7 +284,11 @@ int main(int argc, char *const *argv) {
     }
     if (r) failure_errno("wait/check",r);
     
-    assert(mcr==mc);
+    if (mc) assert(mcr==mc);
+    else mc= mcr;
+    assert(qu==mc->qu);
+    assert(!mc->doneyet);
+    
     fdom_split(mc->fdom,&domain,&qflags,ownflags,sizeof(ownflags));
 
     if (gettimeofday(&now,0)) { perror("gettimeofday"); exit(3); }
diff --git a/regress/case-ndots-as.err b/regress/case-ndots-as.err
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/case-ndots-as.out b/regress/case-ndots-as.out
new file mode 100644 (file)
index 0000000..9c4bb87
--- /dev/null
@@ -0,0 +1,16 @@
+adns debug: using nameserver 172.18.45.6
+newsx.davenant flags 5 type 1 A(-) submitted
+news.davenant flags 5 type 1 A(-) submitted
+news.davenant.greenend.org.uk flags 5 type 1 A(-) submitted
+trunc.test.iwj.relativity flags 5 type 1 A(-) submitted
+trunx.test.iwj.relativity flags 5 type 1 A(-) submitted
+test.iwj.relativity flags 5 type 1 A(-) submitted
+news.davenant.greenend.org.uk flags 5 type A(-): OK; nrrs=1; cname=davenant.relativity.greenend.org.uk; owner=news.davenant.greenend.org.uk; ttl=86400
+ 172.18.45.6
+newsx.davenant flags 5 type A(-): No such domain; nrrs=0; cname=$; owner=newsx.davenant.greenend.org.uk; ttl=86400
+news.davenant flags 5 type A(-): OK; nrrs=1; cname=davenant.relativity.greenend.org.uk; owner=news.davenant.greenend.org.uk; ttl=86400
+ 172.18.45.6
+trunc.test.iwj.relativity flags 5 type A(-): No such data; nrrs=0; cname=$; owner=trunc.test.iwj.relativity.greenend.org.uk; ttl=60
+trunx.test.iwj.relativity flags 5 type A(-): No such domain; nrrs=0; cname=$; owner=trunx.test.iwj.relativity.greenend.org.uk; ttl=60
+test.iwj.relativity flags 5 type A(-): No such data; nrrs=0; cname=$; owner=test.iwj.relativity.greenend.org.uk; ttl=60
+rc=0
diff --git a/regress/case-ndots-as.sys b/regress/case-ndots-as.sys
new file mode 100644 (file)
index 0000000..b5f6e5a
--- /dev/null
@@ -0,0 +1,316 @@
+default
+:1 5/newsx.davenant 5/news.davenant 5/news.davenant.greenend.org.uk 5/trunc.test.iwj.relativity 5/trunx.test.iwj.relativity 5/test.iwj.relativity
+ start 931992163.221752
+ socket type=SOCK_DGRAM
+ socket=4
+ +0.000186
+ fcntl fd=4 cmd=F_GETFL
+ fcntl=~O_NONBLOCK&...
+ +0.000086
+ fcntl fd=4 cmd=F_SETFL O_NONBLOCK|...
+ fcntl=OK
+ +0.000066
+ sendto fd=4 addr=172.18.45.6:53
+     311f0100 00010000 00000000 056e6577 73780864 6176656e 616e7400 00010001.
+ sendto=32
+ +0.000567
+ sendto fd=4 addr=172.18.45.6:53
+     31200100 00010000 00000000 046e6577 73086461 76656e61 6e740000 010001.
+ sendto=31
+ +0.000453
+ sendto fd=4 addr=172.18.45.6:53
+     31210100 00010000 00000000 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001.
+ sendto=47
+ +0.000507
+ sendto fd=4 addr=172.18.45.6:53
+     31220100 00010000 00000000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790000 010001.
+ sendto=43
+ +0.000479
+ sendto fd=4 addr=172.18.45.6:53
+     31230100 00010000 00000000 05747275 6e780474 65737403 69776a0a 72656c61
+     74697669 74790000 010001.
+ sendto=43
+ +0.000624
+ sendto fd=4 addr=172.18.45.6:53
+     31240100 00010000 00000000 04746573 74036977 6a0a7265 6c617469 76697479
+     00000100 01.
+ sendto=37
+ +0.000457
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.996913
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.022284
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31218580 00010002 00030003 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001c0 0c000500 01000151 80002508 64617665
+     6e616e74 0a72656c 61746976 69747908 67726565 6e656e64 036f7267 02756b00
+     c03b0001 00010001 51800004 ac122d06 c0440002 00010001 51800006 036e7330
+     c044c044 00020001 00015180 0006036e 7331c044 c0440002 00010001 51800006
+     036e7332 c044c07c 00010001 00015180 0004ac12 2d06c08e 00010001 00015180
+     0004ac12 2d41c0a0 00010001 00015180 0004ac12 2d01.
+ +0.001420
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000291
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.972918
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.387236
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     311f8583 00010000 00010000 056e6577 73780864 6176656e 616e7400 00010001
+     00000600 01000151 80003e01 410c524f 4f542d53 45525645 5253034e 4554000a
+     686f7374 6d617374 65720849 4e544552 4e4943c0 3a772768 44000007 08000003
+     8400093a 80000151 80.
+ +0.000745
+ sendto fd=4 addr=172.18.45.6:53
+     31250100 00010000 00000000 056e6577 73780864 6176656e 616e7408 64617665
+     6e616e74 08677265 656e656e 64036f72 6702756b 00000100 01.
+ sendto=57
+ +0.000559
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000102
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.584843
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.005460
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31258583 00010000 00010000 056e6577 73780864 6176656e 616e7408 64617665
+     6e616e74 08677265 656e656e 64036f72 6702756b 00000100 01086772 65656e65
+     6e64036f 72670275 6b000006 00010001 5180002d 026e7306 63686961 726bc039
+     0a686f73 746d6173 746572c0 39772741 34000070 8000001c 2000093a 80000151
+     80.
+ +0.000861
+ sendto fd=4 addr=172.18.45.6:53
+     31260100 00010000 00000000 056e6577 73780864 6176656e 616e7408 67726565
+     6e656e64 036f7267 02756b00 00010001.
+ sendto=48
+ +0.000511
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000100
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.577911
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003716
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31268583 00010000 00010000 056e6577 73780864 6176656e 616e7408 67726565
+     6e656e64 036f7267 02756b00 00010001 08677265 656e656e 64036f72 6702756b
+     00000600 01000151 80002d02 6e730663 68696172 6bc0300a 686f7374 6d617374
+     6572c030 77274134 00007080 00001c20 00093a80 00015180.
+ +0.000808
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000127
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.573260
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.075508
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31208583 00010000 00010000 046e6577 73086461 76656e61 6e740000 01000100
+     00060001 00015180 003e0141 0c524f4f 542d5345 52564552 53034e45 54000a68
+     6f73746d 61737465 7208494e 5445524e 4943c039 77276844 00000708 00000384
+     00093a80 00015180.
+ +0.000755
+ sendto fd=4 addr=172.18.45.6:53
+     31270100 00010000 00000000 046e6577 73086461 76656e61 6e740864 6176656e
+     616e7408 67726565 6e656e64 036f7267 02756b00 00010001.
+ sendto=56
+ +0.000532
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000101
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.497324
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.005326
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31278583 00010000 00010000 046e6577 73086461 76656e61 6e740864 6176656e
+     616e7408 67726565 6e656e64 036f7267 02756b00 00010001 08677265 656e656e
+     64036f72 6702756b 00000600 01000151 80002d02 6e730663 68696172 6bc0380a
+     686f7374 6d617374 6572c038 77274134 00007080 00001c20 00093a80 00015180.
+ +0.000855
+ sendto fd=4 addr=172.18.45.6:53
+     31280100 00010000 00000000 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001.
+ sendto=47
+ +0.000503
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000100
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.490540
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.007220
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31288580 00010002 00030003 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001c0 0c000500 01000151 80002508 64617665
+     6e616e74 0a72656c 61746976 69747908 67726565 6e656e64 036f7267 02756b00
+     c03b0001 00010001 51800004 ac122d06 c0440002 00010001 51800006 036e7330
+     c044c044 00020001 00015180 0006036e 7331c044 c0440002 00010001 51800006
+     036e7332 c044c07c 00010001 00015180 0004ac12 2d06c08e 00010001 00015180
+     0004ac12 2d41c0a0 00010001 00015180 0004ac12 2d01.
+ +0.001356
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000223
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.481741
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.023419
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31228583 00010000 00010000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790000 01000100 00060001 00015180 003e0141 0c524f4f 542d5345
+     52564552 53034e45 54000a68 6f73746d 61737465 7208494e 5445524e 4943c045
+     77276844 00000708 00000384 00093a80 00015180.
+ +0.000802
+ sendto fd=4 addr=172.18.45.6:53
+     31290100 00010000 00000000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790864 6176656e 616e7408 67726565 6e656e64 036f7267 02756b00
+     00010001.
+ sendto=68
+ +0.000607
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000101
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.457291
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.005416
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31298583 00010000 00010000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790864 6176656e 616e7408 67726565 6e656e64 036f7267 02756b00
+     00010001 08677265 656e656e 64036f72 6702756b 00000600 01000151 80002d02
+     6e730663 68696172 6bc0440a 686f7374 6d617374 6572c044 77274134 00007080
+     00001c20 00093a80 00015180.
+ +0.000925
+ sendto fd=4 addr=172.18.45.6:53
+     312a0100 00010000 00000000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790867 7265656e 656e6403 6f726702 756b0000 010001.
+ sendto=59
+ +0.000575
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000101
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.450274
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.006009
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312a8580 00010000 00010000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790867 7265656e 656e6403 6f726702 756b0000 01000104 74657374
+     0369776a 0a72656c 61746976 69747908 67726565 6e656e64 036f7267 02756b00
+     00060001 0000003c 0027036e 7330c044 0a686f73 746d6173 746572c0 44000000
+     1800000e 10000000 780064c8 00000000 3c.
+ +0.000954
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000145
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.443166
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.014229
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31238583 00010000 00010000 05747275 6e780474 65737403 69776a0a 72656c61
+     74697669 74790000 01000100 00060001 00015180 003e0141 0c524f4f 542d5345
+     52564552 53034e45 54000a68 6f73746d 61737465 7208494e 5445524e 4943c045
+     77276844 00000708 00000384 00093a80 00015180.
+ +0.000805
+ sendto fd=4 addr=172.18.45.6:53
+     312b0100 00010000 00000000 05747275 6e780474 65737403 69776a0a 72656c61
+     74697669 74790864 6176656e 616e7408 67726565 6e656e64 036f7267 02756b00
+     00010001.
+ sendto=68
+ +0.000606
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000101
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.428049
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.005331
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312b8583 00010000 00010000 05747275 6e780474 65737403 69776a0a 72656c61
+     74697669 74790864 6176656e 616e7408 67726565 6e656e64 036f7267 02756b00
+     00010001 08677265 656e656e 64036f72 6702756b 00000600 01000151 80002d02
+     6e730663 68696172 6bc0440a 686f7374 6d617374 6572c044 77274134 00007080
+     00001c20 00093a80 00015180.
+ +0.000923
+ sendto fd=4 addr=172.18.45.6:53
+     312c0100 00010000 00000000 05747275 6e780474 65737403 69776a0a 72656c61
+     74697669 74790867 7265656e 656e6403 6f726702 756b0000 010001.
+ sendto=59
+ +0.000584
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000101
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.421110
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.004042
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312c8583 00010000 00010000 05747275 6e780474 65737403 69776a0a 72656c61
+     74697669 74790867 7265656e 656e6403 6f726702 756b0000 01000104 74657374
+     0369776a 0a72656c 61746976 69747908 67726565 6e656e64 036f7267 02756b00
+     00060001 0000003c 0027036e 7330c044 0a686f73 746d6173 746572c0 44000000
+     1800000e 10000000 780064c8 00000000 3c.
+ +0.000951
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000153
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.415964
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.026227
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31248583 00010000 00010000 04746573 74036977 6a0a7265 6c617469 76697479
+     00000100 01000006 00010001 5180003e 01410c52 4f4f542d 53455256 45525303
+     4e455400 0a686f73 746d6173 74657208 494e5445 524e4943 c03f7727 68440000
+     07080000 03840009 3a800001 5180.
+ +0.000817
+ sendto fd=4 addr=172.18.45.6:53
+     312d0100 00010000 00000000 04746573 74036977 6a0a7265 6c617469 76697479
+     08646176 656e616e 74086772 65656e65 6e64036f 72670275 6b000001 0001.
+ sendto=62
+ +0.000579
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000102
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.998502
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.005185
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312d8583 00010000 00010000 04746573 74036977 6a0a7265 6c617469 76697479
+     08646176 656e616e 74086772 65656e65 6e64036f 72670275 6b000001 00010867
+     7265656e 656e6403 6f726702 756b0000 06000100 01518000 2d026e73 06636869
+     61726bc0 3e0a686f 73746d61 73746572 c03e7727 41340000 70800000 1c200009
+     3a800001 5180.
+ +0.000918
+ sendto fd=4 addr=172.18.45.6:53
+     312e0100 00010000 00000000 04746573 74036977 6a0a7265 6c617469 76697479
+     08677265 656e656e 64036f72 6702756b 00000100 01.
+ sendto=53
+ +0.000524
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000102
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.998456
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.004007
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312e8580 00010000 00010000 04746573 74036977 6a0a7265 6c617469 76697479
+     08677265 656e656e 64036f72 6702756b 00000100 01c00c00 06000100 00003c00
+     41036e73 300a7265 6c617469 76697479 08677265 656e656e 64036f72 6702756b
+     000a686f 73746d61 73746572 c0450000 00180000 0e100000 00780064 c8000000
+     003c.
+ +0.000867
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000175
+ close fd=4
+ close=OK
+ +0.000183
index 3d1f363ee3fdf20158594a2dede85366791c4309..8367d98952d7deacc18a4935909b8e61054da303 100644 (file)
@@ -1,4 +1,4 @@
-ndots
+ndots -,s
 :1 5/newsx.davenant 5/news.davenant 5/news.davenant.greenend.org.uk 5/trunc.test.iwj.relativity 5/trunx.test.iwj.relativity 5/test.iwj.relativity
  start 924365863.351594
  socket type=SOCK_DGRAM
diff --git a/regress/case-rootqueryall-as.err b/regress/case-rootqueryall-as.err
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/case-rootqueryall-as.out b/regress/case-rootqueryall-as.out
new file mode 100644 (file)
index 0000000..1909c9e
--- /dev/null
@@ -0,0 +1,118 @@
+adns debug: using nameserver 172.18.45.6
+. flags 0 type 1 A(-) submitted
+. flags 0 type 2 NS(raw) submitted
+. flags 0 type 5 CNAME(-) submitted
+. flags 0 type 6 SOA(raw) submitted
+. flags 0 type 12 PTR(raw) submitted
+. flags 0 type 13 HINFO(-) submitted
+. flags 0 type 15 MX(raw) submitted
+. flags 0 type 16 TXT(-) submitted
+. flags 0 type 17 RP(raw) submitted
+. flags 0 type 65537 A(addr) submitted
+. flags 0 type 65538 NS(+addr) submitted
+. flags 0 type 65548 PTR(checked) submitted
+. flags 0 type 65551 MX(+addr) submitted
+. flags 0 type 131078 SOA(822) submitted
+. flags 0 type 131089 RP(822) submitted
+. flags 1 type 1 A(-) submitted
+. flags 1 type 2 NS(raw) submitted
+. flags 1 type 5 CNAME(-) submitted
+. flags 1 type 6 SOA(raw) submitted
+. flags 1 type 12 PTR(raw) submitted
+. flags 1 type 13 HINFO(-) submitted
+. flags 1 type 15 MX(raw) submitted
+. flags 1 type 16 TXT(-) submitted
+. flags 1 type 17 RP(raw) submitted
+. flags 1 type 65537 A(addr) submitted
+. flags 1 type 65538 NS(+addr) submitted
+. flags 1 type 65548 PTR(checked) submitted
+. flags 1 type 65551 MX(+addr) submitted
+. flags 1 type 131078 SOA(822) submitted
+. flags 1 type 131089 RP(822) submitted
+. flags 0 type A(-): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type NS(raw): OK; nrrs=13; cname=$; owner=$; ttl=518399
+ "E.ROOT-SERVERS.NET"
+ "I.ROOT-SERVERS.NET"
+ "F.ROOT-SERVERS.NET"
+ "G.ROOT-SERVERS.NET"
+ "J.ROOT-SERVERS.NET"
+ "K.ROOT-SERVERS.NET"
+ "L.ROOT-SERVERS.NET"
+ "M.ROOT-SERVERS.NET"
+ "A.ROOT-SERVERS.NET"
+ "H.ROOT-SERVERS.NET"
+ "B.ROOT-SERVERS.NET"
+ "C.ROOT-SERVERS.NET"
+ "D.ROOT-SERVERS.NET"
+. flags 0 type SOA(raw): OK; nrrs=1; cname=$; owner=$; ttl=82079
+ "A.ROOT-SERVERS.NET" "hostmaster.INTERNIC.NET" 1999071300 1800 900 604800 86400
+. flags 0 type PTR(raw): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type HINFO(-): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type MX(raw): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type TXT(-): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type RP(raw): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type A(addr): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type NS(+addr): OK; nrrs=13; cname=$; owner=$; ttl=518399
+ "I.ROOT-SERVERS.NET": AF_INET 192.36.148.17
+ "F.ROOT-SERVERS.NET": AF_INET 192.5.5.241
+ "G.ROOT-SERVERS.NET": AF_INET 192.112.36.4
+ "J.ROOT-SERVERS.NET": AF_INET 198.41.0.10
+ "K.ROOT-SERVERS.NET": AF_INET 193.0.14.129
+ "L.ROOT-SERVERS.NET": AF_INET 198.32.64.12
+ "M.ROOT-SERVERS.NET": AF_INET 202.12.27.33
+ "A.ROOT-SERVERS.NET": AF_INET 198.41.0.4
+ "H.ROOT-SERVERS.NET": AF_INET 128.63.2.53
+ "B.ROOT-SERVERS.NET": AF_INET 128.9.0.107
+ "C.ROOT-SERVERS.NET": AF_INET 192.33.4.12
+ "D.ROOT-SERVERS.NET": AF_INET 128.8.10.90
+ "E.ROOT-SERVERS.NET": AF_INET 192.203.230.10
+. flags 0 type PTR(checked): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type MX(+addr): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type SOA(822): OK; nrrs=1; cname=$; owner=$; ttl=77975
+ "A.ROOT-SERVERS.NET" "hostmaster@INTERNIC.NET" 1999071300 1800 900 604800 86400
+. flags 0 type RP(822): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type A(-): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type NS(raw): OK; nrrs=13; cname=$; owner=$; ttl=518399
+ "F.ROOT-SERVERS.NET"
+ "G.ROOT-SERVERS.NET"
+ "J.ROOT-SERVERS.NET"
+ "K.ROOT-SERVERS.NET"
+ "L.ROOT-SERVERS.NET"
+ "M.ROOT-SERVERS.NET"
+ "A.ROOT-SERVERS.NET"
+ "H.ROOT-SERVERS.NET"
+ "B.ROOT-SERVERS.NET"
+ "C.ROOT-SERVERS.NET"
+ "D.ROOT-SERVERS.NET"
+ "E.ROOT-SERVERS.NET"
+ "I.ROOT-SERVERS.NET"
+. flags 1 type SOA(raw): OK; nrrs=1; cname=$; owner=$; ttl=74076
+ "A.ROOT-SERVERS.NET" "hostmaster.INTERNIC.NET" 1999071300 1800 900 604800 86400
+. flags 1 type PTR(raw): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type HINFO(-): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type MX(raw): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type TXT(-): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type RP(raw): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type A(addr): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type NS(+addr): OK; nrrs=13; cname=$; owner=$; ttl=518399
+ "G.ROOT-SERVERS.NET": AF_INET 192.112.36.4
+ "J.ROOT-SERVERS.NET": AF_INET 198.41.0.10
+ "K.ROOT-SERVERS.NET": AF_INET 193.0.14.129
+ "L.ROOT-SERVERS.NET": AF_INET 198.32.64.12
+ "M.ROOT-SERVERS.NET": AF_INET 202.12.27.33
+ "A.ROOT-SERVERS.NET": AF_INET 198.41.0.4
+ "H.ROOT-SERVERS.NET": AF_INET 128.63.2.53
+ "B.ROOT-SERVERS.NET": AF_INET 128.9.0.107
+ "C.ROOT-SERVERS.NET": AF_INET 192.33.4.12
+ "D.ROOT-SERVERS.NET": AF_INET 128.8.10.90
+ "E.ROOT-SERVERS.NET": AF_INET 192.203.230.10
+ "I.ROOT-SERVERS.NET": AF_INET 192.36.148.17
+ "F.ROOT-SERVERS.NET": AF_INET 192.5.5.241
+. flags 1 type PTR(checked): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type MX(+addr): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 1 type SOA(822): OK; nrrs=1; cname=$; owner=$; ttl=70372
+ "A.ROOT-SERVERS.NET" "hostmaster@INTERNIC.NET" 1999071300 1800 900 604800 86400
+. flags 1 type RP(822): No such data; nrrs=0; cname=$; owner=$; ttl=599
+. flags 0 type CNAME(-): No such data; nrrs=0; cname=$; owner=$; ttl=86400
+. flags 1 type CNAME(-): No such data; nrrs=0; cname=$; owner=$; ttl=86400
+rc=0
diff --git a/regress/case-rootqueryall-as.sys b/regress/case-rootqueryall-as.sys
new file mode 100644 (file)
index 0000000..532d875
--- /dev/null
@@ -0,0 +1,579 @@
+default
+. 1/.
+ start 931992019.753022
+ socket type=SOCK_DGRAM
+ socket=4
+ +0.000216
+ fcntl fd=4 cmd=F_GETFL
+ fcntl=~O_NONBLOCK&...
+ +0.000082
+ fcntl fd=4 cmd=F_SETFL O_NONBLOCK|...
+ fcntl=OK
+ +0.000065
+ sendto fd=4 addr=172.18.45.6:53
+     311f0100 00010000 00000000 00000100 01.
+ sendto=17
+ +0.000454
+ sendto fd=4 addr=172.18.45.6:53
+     31200100 00010000 00000000 00000200 01.
+ sendto=17
+ +0.000348
+ sendto fd=4 addr=172.18.45.6:53
+     31210100 00010000 00000000 00000500 01.
+ sendto=17
+ +0.000303
+ sendto fd=4 addr=172.18.45.6:53
+     31220100 00010000 00000000 00000600 01.
+ sendto=17
+ +0.000298
+ sendto fd=4 addr=172.18.45.6:53
+     31230100 00010000 00000000 00000c00 01.
+ sendto=17
+ +0.000298
+ sendto fd=4 addr=172.18.45.6:53
+     31240100 00010000 00000000 00000d00 01.
+ sendto=17
+ +0.000375
+ sendto fd=4 addr=172.18.45.6:53
+     31250100 00010000 00000000 00000f00 01.
+ sendto=17
+ +0.000301
+ sendto fd=4 addr=172.18.45.6:53
+     31260100 00010000 00000000 00001000 01.
+ sendto=17
+ +0.000299
+ sendto fd=4 addr=172.18.45.6:53
+     31270100 00010000 00000000 00001100 01.
+ sendto=17
+ +0.000351
+ sendto fd=4 addr=172.18.45.6:53
+     31280100 00010000 00000000 00000100 01.
+ sendto=17
+ +0.000868
+ sendto fd=4 addr=172.18.45.6:53
+     31290100 00010000 00000000 00000200 01.
+ sendto=17
+ +0.000318
+ sendto fd=4 addr=172.18.45.6:53
+     312a0100 00010000 00000000 00000c00 01.
+ sendto=17
+ +0.000299
+ sendto fd=4 addr=172.18.45.6:53
+     312b0100 00010000 00000000 00000f00 01.
+ sendto=17
+ +0.000299
+ sendto fd=4 addr=172.18.45.6:53
+     312c0100 00010000 00000000 00000600 01.
+ sendto=17
+ +0.000297
+ sendto fd=4 addr=172.18.45.6:53
+     312d0100 00010000 00000000 00001100 01.
+ sendto=17
+ +0.000297
+ sendto fd=4 addr=172.18.45.6:53
+     312e0100 00010000 00000000 00000100 01.
+ sendto=17
+ +0.000307
+ sendto fd=4 addr=172.18.45.6:53
+     312f0100 00010000 00000000 00000200 01.
+ sendto=17
+ +0.000299
+ sendto fd=4 addr=172.18.45.6:53
+     31300100 00010000 00000000 00000500 01.
+ sendto=17
+ +0.000298
+ sendto fd=4 addr=172.18.45.6:53
+     31310100 00010000 00000000 00000600 01.
+ sendto=17
+ +0.000330
+ sendto fd=4 addr=172.18.45.6:53
+     31320100 00010000 00000000 00000c00 01.
+ sendto=17
+ +0.000323
+ sendto fd=4 addr=172.18.45.6:53
+     31330100 00010000 00000000 00000d00 01.
+ sendto=17
+ +0.000384
+ sendto fd=4 addr=172.18.45.6:53
+     31340100 00010000 00000000 00000f00 01.
+ sendto=17
+ +0.000302
+ sendto fd=4 addr=172.18.45.6:53
+     31350100 00010000 00000000 00001000 01.
+ sendto=17
+ +0.000300
+ sendto fd=4 addr=172.18.45.6:53
+     31360100 00010000 00000000 00001100 01.
+ sendto=17
+ +0.000296
+ sendto fd=4 addr=172.18.45.6:53
+     31370100 00010000 00000000 00000100 01.
+ sendto=17
+ +0.000298
+ sendto fd=4 addr=172.18.45.6:53
+     31380100 00010000 00000000 00000200 01.
+ sendto=17
+ +0.000298
+ sendto fd=4 addr=172.18.45.6:53
+     31390100 00010000 00000000 00000c00 01.
+ sendto=17
+ +0.000297
+ sendto fd=4 addr=172.18.45.6:53
+     313a0100 00010000 00000000 00000f00 01.
+ sendto=17
+ +0.000296
+ sendto fd=4 addr=172.18.45.6:53
+     313b0100 00010000 00000000 00000600 01.
+ sendto=17
+ +0.000326
+ sendto fd=4 addr=172.18.45.6:53
+     313c0100 00010000 00000000 00001100 01.
+ sendto=17
+ +0.000303
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.989938
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.007735
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     311f8180 00010000 00010000 00000100 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000703
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000151
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.981803
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.011771
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31208180 0001000d 0000000d 00000200 01000002 00010007 e8ff0014 01450c52
+     4f4f542d 53455256 45525303 4e455400 00000200 010007e8 ff000401 49c01e00
+     00020001 0007e8ff 00040146 c01e0000 02000100 07e8ff00 040147c0 1e000002
+     00010007 e8ff0004 014ac01e 00000200 010007e8 ff000401 4bc01e00 00020001
+     0007e8ff 0004014c c01e0000 02000100 07e8ff00 04014dc0 1e000002 00010007
+     e8ff0004 0141c01e 00000200 010007e8 ff000401 48c01e00 00020001 0007e8ff
+     00040142 c01e0000 02000100 07e8ff00 040143c0 1e000002 00010007 e8ff0004
+     0144c01e c01c0001 00010009 3a7f0004 c0cbe60a c03b0001 00010009 3a7f0004
+     c0249411 c04a0001 00010009 3a7f0004 c00505f1 c0590001 00010009 3a7f0004
+     c0702404 c0680001 00010009 3a7f0004 c629000a c0770001 00010009 3a7f0004
+     c1000e81 c0860001 00010009 3a7f0004 c620400c c0950001 00010009 3a7f0004
+     ca0c1b21 c0a40001 00010009 3a7f0004 c6290004 c0b30001 00010009 3a7f0004
+     803f0235 c0c20001 00010009 3a7f0004 8009006b c0d10001 00010009 3a7f0004
+     c021040c c0e00001 00010009 3a7f0004 80080a5a.
+ +0.002660
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000492
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.967228
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.016740
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31228180 00010001 000d000d 00000600 01000006 00010001 409f003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 51800000 02000100
+     07e8ff00 040145c0 1e000002 00010007 e8ff0004 0149c01e 00000200 010007e8
+     ff000401 46c01e00 00020001 0007e8ff 00040147 c01e0000 02000100 07e8ff00
+     04014ac0 1e000002 00010007 e8ff0004 014bc01e 00000200 010007e8 ff000401
+     4cc01e00 00020001 0007e8ff 0004014d c01e0000 02000100 07e8ff00 02c01c00
+     00020001 0007e8ff 00040148 c01e0000 02000100 07e8ff00 040142c0 1e000002
+     00010007 e8ff0004 0143c01e 00000200 010007e8 ff000401 44c01ec0 65000100
+     0100093a 7f0004c0 cbe60ac0 74000100 0100093a 7f0004c0 249411c0 83000100
+     0100093a 7f0004c0 0505f1c0 92000100 0100093a 7f0004c0 702404c0 a1000100
+     0100093a 7f0004c6 29000ac0 b0000100 0100093a 7f0004c1 000e81c0 bf000100
+     0100093a 7f0004c6 20400cc0 ce000100 0100093a 7f0004ca 0c1b21c0 1c000100
+     0100093a 7f0004c6 290004c0 ea000100 0100093a 7f000480 3f0235c0 f9000100
+     0100093a 7f000480 09006bc1 08000100 0100093a 7f0004c0 21040cc1 17000100
+     0100093a 7f000480 080a5a.
+ +0.002984
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000231
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.947273
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.000462
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31238180 00010000 00010000 00000c00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000634
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000101
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.946076
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003306
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31248180 00010000 00010000 00000d00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000640
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000124
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.942006
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003471
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31258180 00010000 00010000 00000f00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000640
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000101
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.937794
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003503
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31268180 00010000 00010000 00001000 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000657
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000120
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.933514
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003470
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31278180 00010000 00010000 00001100 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000640
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000100
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.929304
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003089
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31288180 00010000 00010000 00000100 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000639
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000100
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.925476
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.011378
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31298180 0001000d 0000000d 00000200 01000002 00010007 e8ff0014 01490c52
+     4f4f542d 53455256 45525303 4e455400 00000200 010007e8 ff000401 46c01e00
+     00020001 0007e8ff 00040147 c01e0000 02000100 07e8ff00 04014ac0 1e000002
+     00010007 e8ff0004 014bc01e 00000200 010007e8 ff000401 4cc01e00 00020001
+     0007e8ff 0004014d c01e0000 02000100 07e8ff00 040141c0 1e000002 00010007
+     e8ff0004 0148c01e 00000200 010007e8 ff000401 42c01e00 00020001 0007e8ff
+     00040143 c01e0000 02000100 07e8ff00 040144c0 1e000002 00010007 e8ff0004
+     0145c01e c01c0001 00010009 3a7f0004 c0249411 c03b0001 00010009 3a7f0004
+     c00505f1 c04a0001 00010009 3a7f0004 c0702404 c0590001 00010009 3a7f0004
+     c629000a c0680001 00010009 3a7f0004 c1000e81 c0770001 00010009 3a7f0004
+     c620400c c0860001 00010009 3a7f0004 ca0c1b21 c0950001 00010009 3a7f0004
+     c6290004 c0a40001 00010009 3a7f0004 803f0235 c0b30001 00010009 3a7f0004
+     8009006b c0c20001 00010009 3a7f0004 c021040c c0d10001 00010009 3a7f0004
+     80080a5a c0e00001 00010009 3a7f0004 c0cbe60a.
+ +0.002666
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312a8180 00010000 00010000 00000c00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.001684
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000096
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.909652
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003338
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312b8180 00010000 00010000 00000f00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000643
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000106
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.905565
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.012071
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312c8180 00010001 000d000d 00000600 01000006 00010001 3097003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 51800000 02000100
+     07e8ff00 040149c0 1e000002 00010007 e8ff0004 0146c01e 00000200 010007e8
+     ff000401 47c01e00 00020001 0007e8ff 0004014a c01e0000 02000100 07e8ff00
+     04014bc0 1e000002 00010007 e8ff0004 014cc01e 00000200 010007e8 ff000401
+     4dc01e00 00020001 0007e8ff 0002c01c 00000200 010007e8 ff000401 48c01e00
+     00020001 0007e8ff 00040142 c01e0000 02000100 07e8ff00 040143c0 1e000002
+     00010007 e8ff0004 0144c01e 00000200 010007e8 ff000401 45c01ec0 65000100
+     0100093a 7f0004c0 249411c0 74000100 0100093a 7f0004c0 0505f1c0 83000100
+     0100093a 7f0004c0 702404c0 92000100 0100093a 7f0004c6 29000ac0 a1000100
+     0100093a 7f0004c1 000e81c0 b0000100 0100093a 7f0004c6 20400cc0 bf000100
+     0100093a 7f0004ca 0c1b21c0 1c000100 0100093a 7f0004c6 290004c0 db000100
+     0100093a 7f000480 3f0235c0 ea000100 0100093a 7f000480 09006bc0 f9000100
+     0100093a 7f0004c0 21040cc1 08000100 0100093a 7f000480 080a5ac1 17000100
+     0100093a 7f0004c0 cbe60a.
+ +0.002963
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000237
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.890294
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.000878
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312d8180 00010000 00010000 00001100 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000645
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000107
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.888664
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003147
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312e8180 00010000 00010000 00000100 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000643
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000141
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.884733
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.011290
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312f8180 0001000d 0000000d 00000200 01000002 00010007 e8ff0014 01460c52
+     4f4f542d 53455256 45525303 4e455400 00000200 010007e8 ff000401 47c01e00
+     00020001 0007e8ff 0004014a c01e0000 02000100 07e8ff00 04014bc0 1e000002
+     00010007 e8ff0004 014cc01e 00000200 010007e8 ff000401 4dc01e00 00020001
+     0007e8ff 00040141 c01e0000 02000100 07e8ff00 040148c0 1e000002 00010007
+     e8ff0004 0142c01e 00000200 010007e8 ff000401 43c01e00 00020001 0007e8ff
+     00040144 c01e0000 02000100 07e8ff00 040145c0 1e000002 00010007 e8ff0004
+     0149c01e c01c0001 00010009 3a7f0004 c00505f1 c03b0001 00010009 3a7f0004
+     c0702404 c04a0001 00010009 3a7f0004 c629000a c0590001 00010009 3a7f0004
+     c1000e81 c0680001 00010009 3a7f0004 c620400c c0770001 00010009 3a7f0004
+     ca0c1b21 c0860001 00010009 3a7f0004 c6290004 c0950001 00010009 3a7f0004
+     803f0235 c0a40001 00010009 3a7f0004 8009006b c0b30001 00010009 3a7f0004
+     c021040c c0c20001 00010009 3a7f0004 80080a5a c0d10001 00010009 3a7f0004
+     c0cbe60a c0e00001 00010009 3a7f0004 c0249411.
+ +0.002658
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000400
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.870385
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.019033
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31318180 00010001 000d000d 00000600 01000006 00010001 215c003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 51800000 02000100
+     07e8ff00 040146c0 1e000002 00010007 e8ff0004 0147c01e 00000200 010007e8
+     ff000401 4ac01e00 00020001 0007e8ff 0004014b c01e0000 02000100 07e8ff00
+     04014cc0 1e000002 00010007 e8ff0004 014dc01e 00000200 010007e8 ff0002c0
+     1c000002 00010007 e8ff0004 0148c01e 00000200 010007e8 ff000401 42c01e00
+     00020001 0007e8ff 00040143 c01e0000 02000100 07e8ff00 040144c0 1e000002
+     00010007 e8ff0004 0145c01e 00000200 010007e8 ff000401 49c01ec0 65000100
+     0100093a 7f0004c0 0505f1c0 74000100 0100093a 7f0004c0 702404c0 83000100
+     0100093a 7f0004c6 29000ac0 92000100 0100093a 7f0004c1 000e81c0 a1000100
+     0100093a 7f0004c6 20400cc0 b0000100 0100093a 7f0004ca 0c1b21c0 1c000100
+     0100093a 7f0004c6 290004c0 cc000100 0100093a 7f000480 3f0235c0 db000100
+     0100093a 7f000480 09006bc0 ea000100 0100093a 7f0004c0 21040cc0 f9000100
+     0100093a 7f000480 080a5ac1 08000100 0100093a 7f0004c0 cbe60ac1 17000100
+     0100093a 7f0004c0 249411.
+ +0.002965
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000228
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.848159
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.000402
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31328180 00010000 00010000 00000c00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000658
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000104
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.846995
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003222
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31338180 00010000 00010000 00000d00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000645
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000107
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.843021
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003535
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31348180 00010000 00010000 00000f00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000640
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000128
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.838718
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003396
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31358180 00010000 00010000 00001000 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000643
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000108
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.834571
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003560
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31368180 00010000 00010000 00001100 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000642
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000133
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.830236
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003060
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31378180 00010000 00010000 00000100 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000645
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000106
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.826425
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.011323
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31388180 0001000d 0000000d 00000200 01000002 00010007 e8ff0014 01470c52
+     4f4f542d 53455256 45525303 4e455400 00000200 010007e8 ff000401 4ac01e00
+     00020001 0007e8ff 0004014b c01e0000 02000100 07e8ff00 04014cc0 1e000002
+     00010007 e8ff0004 014dc01e 00000200 010007e8 ff000401 41c01e00 00020001
+     0007e8ff 00040148 c01e0000 02000100 07e8ff00 040142c0 1e000002 00010007
+     e8ff0004 0143c01e 00000200 010007e8 ff000401 44c01e00 00020001 0007e8ff
+     00040145 c01e0000 02000100 07e8ff00 040149c0 1e000002 00010007 e8ff0004
+     0146c01e c01c0001 00010009 3a7f0004 c0702404 c03b0001 00010009 3a7f0004
+     c629000a c04a0001 00010009 3a7f0004 c1000e81 c0590001 00010009 3a7f0004
+     c620400c c0680001 00010009 3a7f0004 ca0c1b21 c0770001 00010009 3a7f0004
+     c6290004 c0860001 00010009 3a7f0004 803f0235 c0950001 00010009 3a7f0004
+     8009006b c0a40001 00010009 3a7f0004 c021040c c0b30001 00010009 3a7f0004
+     80080a5a c0c20001 00010009 3a7f0004 c0cbe60a c0d10001 00010009 3a7f0004
+     c0249411 c0e00001 00010009 3a7f0004 c00505f1.
+ +0.002663
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31398180 00010000 00010000 00000c00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.001663
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000127
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.810649
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003326
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     313a8180 00010000 00010000 00000f00 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000643
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000105
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.806575
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.025669
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     313b8180 00010001 000d000d 00000600 01000006 00010001 12e4003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 51800000 02000100
+     07e8ff00 040147c0 1e000002 00010007 e8ff0004 014ac01e 00000200 010007e8
+     ff000401 4bc01e00 00020001 0007e8ff 0004014c c01e0000 02000100 07e8ff00
+     04014dc0 1e000002 00010007 e8ff0002 c01c0000 02000100 07e8ff00 040148c0
+     1e000002 00010007 e8ff0004 0142c01e 00000200 010007e8 ff000401 43c01e00
+     00020001 0007e8ff 00040144 c01e0000 02000100 07e8ff00 040145c0 1e000002
+     00010007 e8ff0004 0149c01e 00000200 010007e8 ff000401 46c01ec0 65000100
+     0100093a 7f0004c0 702404c0 74000100 0100093a 7f0004c6 29000ac0 83000100
+     0100093a 7f0004c1 000e81c0 92000100 0100093a 7f0004c6 20400cc0 a1000100
+     0100093a 7f0004ca 0c1b21c0 1c000100 0100093a 7f0004c6 290004c0 bd000100
+     0100093a 7f000480 3f0235c0 cc000100 0100093a 7f000480 09006bc0 db000100
+     0100093a 7f0004c0 21040cc0 ea000100 0100093a 7f000480 080a5ac0 f9000100
+     0100093a 7f0004c0 cbe60ac1 08000100 0100093a 7f0004c0 249411c1 17000100
+     0100093a 7f0004c0 0505f1.
+ +0.002963
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000233
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.777710
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.004017
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     313c8180 00010000 00010000 00001100 01000006 00010000 0257003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000640
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000106
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.772947
+ select=1 rfds=[4] wfds=[] efds=[]
+ +1.-752512
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31218580 00010000 00010000 00000500 01000006 00010001 5180003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000649
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000106
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.529913
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.181054
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31308580 00010000 00010000 00000500 01000006 00010001 5180003e 01410c52
+     4f4f542d 53455256 45525303 4e455400 0a686f73 746d6173 74657208 494e5445
+     524e4943 c02b7727 68440000 07080000 03840009 3a800001 5180.
+ +0.000687
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000112
+ close fd=4
+ close=OK
+ +0.000197
index e91891224c00f333c6c4df5b716242f0562285b8..d20c07348f8ae3f9b003e85425fdf40f0d62ca0a 100644 (file)
@@ -1,4 +1,4 @@
-default
+default -,s
 . 1/.
  start 924364450.165424
  socket type=SOCK_DGRAM
diff --git a/regress/case-search-as.err b/regress/case-search-as.err
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/case-search-as.out b/regress/case-search-as.out
new file mode 100644 (file)
index 0000000..95e15a5
--- /dev/null
@@ -0,0 +1,14 @@
+adns debug: using nameserver 172.18.45.6
+news flags 5 type 1 A(-) submitted
+chiark flags 5 type 1 A(-) submitted
+news flags 1 type 1 A(-) submitted
+chiark flags 1 type 1 A(-) submitted
+news flags 5 type A(-): OK; nrrs=1; cname=davenant.relativity.greenend.org.uk; owner=news.davenant.greenend.org.uk; ttl=86400
+ 172.18.45.6
+news flags 1 type A(-): OK; nrrs=1; cname=davenant.relativity.greenend.org.uk; owner=$; ttl=86400
+ 172.18.45.6
+chiark flags 5 type A(-): OK; nrrs=1; cname=$; owner=chiark.greenend.org.uk; ttl=86400
+ 195.224.76.132
+chiark flags 1 type A(-): OK; nrrs=1; cname=$; owner=$; ttl=86400
+ 195.224.76.132
+rc=0
diff --git a/regress/case-search-as.sys b/regress/case-search-as.sys
new file mode 100644 (file)
index 0000000..c741d41
--- /dev/null
@@ -0,0 +1,131 @@
+default
+:1 0x5/news 0x5/chiark 1/news 1/chiark
+ start 931992052.232208
+ socket type=SOCK_DGRAM
+ socket=4
+ +0.000202
+ fcntl fd=4 cmd=F_GETFL
+ fcntl=~O_NONBLOCK&...
+ +0.000109
+ fcntl fd=4 cmd=F_SETFL O_NONBLOCK|...
+ fcntl=OK
+ +0.000065
+ sendto fd=4 addr=172.18.45.6:53
+     311f0100 00010000 00000000 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001.
+ sendto=47
+ +0.000696
+ sendto fd=4 addr=172.18.45.6:53
+     31200100 00010000 00000000 06636869 61726b08 64617665 6e616e74 08677265
+     656e656e 64036f72 6702756b 00000100 01.
+ sendto=49
+ +0.000559
+ sendto fd=4 addr=172.18.45.6:53
+     31210100 00010000 00000000 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001.
+ sendto=47
+ +0.000991
+ sendto fd=4 addr=172.18.45.6:53
+     31220100 00010000 00000000 06636869 61726b08 64617665 6e616e74 08677265
+     656e656e 64036f72 6702756b 00000100 01.
+ sendto=49
+ +0.000516
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.997238
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.019885
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     311f8580 00010002 00030003 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001c0 0c000500 01000151 80002508 64617665
+     6e616e74 0a72656c 61746976 69747908 67726565 6e656e64 036f7267 02756b00
+     c03b0001 00010001 51800004 ac122d06 c0440002 00010001 51800006 036e7330
+     c044c044 00020001 00015180 0006036e 7331c044 c0440002 00010001 51800006
+     036e7332 c044c07c 00010001 00015180 0004ac12 2d06c08e 00010001 00015180
+     0004ac12 2d41c0a0 00010001 00015180 0004ac12 2d01.
+ +0.001537
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000296
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.976216
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.001966
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31208583 00010000 00010000 06636869 61726b08 64617665 6e616e74 08677265
+     656e656e 64036f72 6702756b 00000100 01086772 65656e65 6e64036f 72670275
+     6b000006 00010001 5180002d 026e7306 63686961 726bc031 0a686f73 746d6173
+     746572c0 31772741 34000070 8000001c 2000093a 80000151 80.
+ +0.000819
+ sendto fd=4 addr=172.18.45.6:53
+     31230100 00010000 00000000 06636869 61726b08 67726565 6e656e64 036f7267
+     02756b00 00010001.
+ sendto=40
+ +0.000471
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000102
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.973417
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.006224
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31218580 00010002 00030003 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001c0 0c000500 01000151 80002508 64617665
+     6e616e74 0a72656c 61746976 69747908 67726565 6e656e64 036f7267 02756b00
+     c03b0001 00010001 51800004 ac122d06 c0440002 00010001 51800006 036e7330
+     c044c044 00020001 00015180 0006036e 7331c044 c0440002 00010001 51800006
+     036e7332 c044c07c 00010001 00015180 0004ac12 2d06c08e 00010001 00015180
+     0004ac12 2d41c0a0 00010001 00015180 0004ac12 2d01.
+ +0.001353
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000239
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.966592
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.001978
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31228583 00010000 00010000 06636869 61726b08 64617665 6e616e74 08677265
+     656e656e 64036f72 6702756b 00000100 01086772 65656e65 6e64036f 72670275
+     6b000006 00010001 5180002d 026e7306 63686961 726bc031 0a686f73 746d6173
+     746572c0 31772741 34000070 8000001c 2000093a 80000151 80.
+ +0.000817
+ sendto fd=4 addr=172.18.45.6:53
+     31240100 00010000 00000000 06636869 61726b08 67726565 6e656e64 036f7267
+     02756b00 00010001.
+ sendto=40
+ +0.000436
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000101
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.987460
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.004418
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31238580 00010001 00020002 06636869 61726b08 67726565 6e656e64 036f7267
+     02756b00 00010001 c00c0001 00010001 51800004 c3e04c84 08677265 656e656e
+     64036f72 6702756b 00000200 01000151 80001103 6e73300a 72656c61 74697669
+     7479c038 c0380002 00010001 51800006 036e7331 c057c053 00010001 00015180
+     0004ac12 2d06c070 00010001 00015180 0004ac12 2d41.
+ +0.000982
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000180
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.993066
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.003953
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31248580 00010001 00020002 06636869 61726b08 67726565 6e656e64 036f7267
+     02756b00 00010001 c00c0001 00010001 51800004 c3e04c84 08677265 656e656e
+     64036f72 6702756b 00000200 01000151 80001103 6e73300a 72656c61 74697669
+     7479c038 c0380002 00010001 51800006 036e7331 c057c053 00010001 00015180
+     0004ac12 2d06c070 00010001 00015180 0004ac12 2d41.
+ +0.000986
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000143
+ close fd=4
+ close=OK
+ +0.000193
index f333d6693dc02be5144c6de319ae1dba4d524794..1cbc3010e5c15d3fe17b3af74983133532f01f2e 100644 (file)
@@ -1,4 +1,4 @@
-default
+default -,s
 :1 0x5/news 0x5/chiark 1/news 1/chiark
  start 924360470.478357
  socket type=SOCK_DGRAM
index 4f25dc7246529a5e6e711ea568767539f4b6faa2..996d2829f3aefd20eda06ece3f4e43c6d243c6d3 100644 (file)
@@ -306,7 +306,7 @@ void adns_finish(adns_state ads);
 
 
 void adns_forallqueries_begin(adns_state ads);
-struct adns_query adns_forallqueries_next(adns_state ads, void **context_r);
+adns_query adns_forallqueries_next(adns_state ads, void **context_r);
 /* Iterator functions, which you can use to loop over the outstanding
  * (submitted but not yet successfuly checked/waited) queries.
  *
@@ -319,7 +319,7 @@ struct adns_query adns_forallqueries_next(adns_state ads, void **context_r);
  * query in the same adns_state).  There is no need to explicitly
  * finish an iteration.
  *
- * context_r may be 0.
+ * context_r may be 0.  *context_r may not be set when _next returns 0.
  */
 
 /*
index 0115e070b287d4d8b3fd7d11c02ee0455ce9f948..4d43a8be2d8abdfbf44743b0103a5a4cb4cf7f9f 100644 (file)
@@ -526,6 +526,7 @@ static int internal_check(adns_state ads,
   LIST_UNLINK(ads->output,qu);
   *answer= qu->answer;
   if (context_r) *context_r= qu->ctx.ext;
+  *query_io= qu;
   free(qu);
   return 0;
 }
index dadd854a88e42c05b75a88471bc446f90ba21988..e6b16aaa9c4bd6eb62bab47f739ba05355309668 100644 (file)
@@ -158,7 +158,7 @@ struct adns__query {
   struct { allocnode *head, *tail; } allocations;
   int interim_allocd;
   void *final_allocspace;
-  
+
   const typeinfo *typei;
   byte *query_dgram;
   int query_dglen;
@@ -264,6 +264,7 @@ struct adns__state {
   FILE *diagfile;
   int configerrno;
   struct { adns_query head, tail; } timew, childw, output;
+  adns_query forallnext;
   int nextid, udpsocket, tcpsocket;
   vbuf tcpsend, tcprecv;
   int nservers, nsortlist, nsearchlist, searchndots, tcpserver;
index 2765dc4a8d3c884fb3ccc785f38bed549216447c..99cf02a49ccda5fc7401222f331ee6c16494f3c3 100644 (file)
@@ -444,6 +444,7 @@ static int init_begin(adns_state *ads_r, adns_initflags flags, FILE *diagfile) {
   LIST_INIT(ads->timew);
   LIST_INIT(ads->childw);
   LIST_INIT(ads->output);
+  ads->forallnext= 0;
   ads->nextid= 0x311f;
   ads->udpsocket= ads->tcpsocket= -1;
   adns__vbuf_init(&ads->tcpsend);
@@ -565,3 +566,29 @@ void adns_finish(adns_state ads) {
   adns__vbuf_free(&ads->tcprecv);
   free(ads);
 }
+
+void adns_forallqueries_begin(adns_state ads) {
+  ads->forallnext=
+    ads->timew.head ? ads->timew.head :
+    ads->childw.head ? ads->childw.head :
+    ads->output.head;
+}
+  
+adns_query adns_forallqueries_next(adns_state ads, void **context_r) {
+  adns_query qu, nqu;
+
+  nqu= ads->forallnext;
+  for (;;) {
+    qu= nqu;
+    if (!qu) return 0;
+    nqu=
+      qu->next ? qu->next :
+      qu == ads->timew.tail ? (ads->childw.head ? ads->childw.head : ads->output.head) :
+      qu == ads->childw.tail ? ads->output.head :
+      0;
+    if (!qu->parent) break;
+  }
+  ads->forallnext= nqu;
+  if (context_r) *context_r= qu->ctx.ext;
+  return qu;
+}