chiark / gitweb /
option debug and option ndots implemented
authorian <ian>
Sat, 17 Apr 1999 16:23:11 +0000 (16:23 +0000)
committerian <ian>
Sat, 17 Apr 1999 16:23:11 +0000 (16:23 +0000)
21 files changed:
regress/case-mailboxes.out
regress/case-manya.out
regress/case-ndots.err [new file with mode: 0644]
regress/case-ndots.out [new file with mode: 0644]
regress/case-ndots.sys [new file with mode: 0644]
regress/case-ndotsbad.err [new file with mode: 0644]
regress/case-ndotsbad.out [new file with mode: 0644]
regress/case-ndotsbad.sys [new file with mode: 0644]
regress/case-norm.out
regress/case-owner.out
regress/case-rootquery.out
regress/case-rootqueryall.out
regress/case-search.out
regress/case-searchabs.out
regress/case-timeout.out
regress/case-trunc.out
regress/init-ndots.text [new file with mode: 0644]
regress/init-ndotsbad.text [new file with mode: 0644]
regress/m1test
regress/r1test
src/setup.c

index 8b3e1032282519dc14528ae1cdc16f0999bc8146..9bf4e875b9d54e351e0bb2f2e27f0465f2e2d521 100644 (file)
@@ -7,3 +7,4 @@ silly-rp.test.iwj.relativity.greenend.org.uk flags 0 type RP(822): OK; nrrs=6; c
  "\x22i\\.\\.j\x22@ucam.org" ""
  "\x22\\.i\x22@ucam.org" ""
  "\x22i\\.\x22@ucam.org" ""
  "\x22i\\.\\.j\x22@ucam.org" ""
  "\x22\\.i\x22@ucam.org" ""
  "\x22i\\.\x22@ucam.org" ""
+rc=0
index 5134751068427653d03ae76899ebd4ec6e962ca9..08cee50e8b18bdc0cb918ee2dbfd2fc0cc2904c0 100644 (file)
@@ -5,3 +5,4 @@ manyaddrs.test.iwj.relativity.greenend.org.uk flags 0 type A(-): OK; nrrs=4; cna
  172.18.45.6
  172.18.45.1
  172.18.45.35
  172.18.45.6
  172.18.45.1
  172.18.45.35
+rc=0
diff --git a/regress/case-ndots.err b/regress/case-ndots.err
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/case-ndots.out b/regress/case-ndots.out
new file mode 100644 (file)
index 0000000..ceef65a
--- /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
+newsx.davenant flags 5 type A(-): No such domain; nrrs=0; cname=$; owner=newsx.davenant; ttl=175
+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
+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
+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.sys b/regress/case-ndots.sys
new file mode 100644 (file)
index 0000000..83770ba
--- /dev/null
@@ -0,0 +1,277 @@
+ndots
+: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
+ socket=4
+ +0.000212
+ fcntl fd=4 cmd=F_GETFL
+ fcntl=2
+ +0.000087
+ fcntl fd=4 cmd=F_SETFL 2050
+ fcntl=0
+ +0.000069
+ sendto fd=4 addr=172.18.45.6:53
+     311f0100 00010000 00000000 056e6577 73780864 6176656e 616e7408 64617665
+     6e616e74 08677265 656e656e 64036f72 6702756b 00000100 01.
+ sendto=57
+ +0.003433
+ sendto fd=4 addr=172.18.45.6:53
+     31200100 00010000 00000000 046e6577 73086461 76656e61 6e740864 6176656e
+     616e7408 67726565 6e656e64 036f7267 02756b00 00010001.
+ sendto=56
+ +0.001694
+ sendto fd=4 addr=172.18.45.6:53
+     31210100 00010000 00000000 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001.
+ sendto=47
+ +0.001921
+ sendto fd=4 addr=172.18.45.6:53
+     31220100 00010000 00000000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790000 010001.
+ sendto=43
+ +0.001042
+ sendto fd=4 addr=172.18.45.6:53
+     31230100 00010000 00000000 05747275 6e780474 65737403 69776a0a 72656c61
+     74697669 74790000 010001.
+ sendto=43
+ +0.002220
+ sendto fd=4 addr=172.18.45.6:53
+     31240100 00010000 00000000 04746573 74036977 6a0a7265 6c617469 76697479
+     08646176 656e616e 74086772 65656e65 6e64036f 72670275 6b000001 0001.
+ sendto=62
+ +0.001132
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.988558
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.000225
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     311f8583 00010000 00010000 056e6577 73780864 6176656e 616e7408 64617665
+     6e616e74 08677265 656e656e 64036f72 6702756b 00000100 01086772 65656e65
+     6e64036f 72670275 6b000006 00010001 51800037 04646e73 3006656c 6d61696c
+     02636fc0 46087269 63686172 646b0663 68696172 6bc03977 26f0bf00 00708000
+     001c2000 093a8000 015180.
+ +0.000801
+ sendto fd=4 addr=172.18.45.6:53
+     31250100 00010000 00000000 056e6577 73780864 6176656e 616e7408 67726565
+     6e656e64 036f7267 02756b00 00010001.
+ sendto=48
+ +0.001048
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31208583 00010000 00010000 046e6577 73086461 76656e61 6e740864 6176656e
+     616e7408 67726565 6e656e64 036f7267 02756b00 00010001 08677265 656e656e
+     64036f72 6702756b 00000600 01000151 80003704 646e7330 06656c6d 61696c02
+     636fc045 08726963 68617264 6b066368 6961726b c0387726 f0bf0000 70800000
+     1c200009 3a800001 5180.
+ +0.000773
+ sendto fd=4 addr=172.18.45.6:53
+     31260100 00010000 00000000 046e6577 73086461 76656e61 6e740867 7265656e
+     656e6403 6f726702 756b0000 010001.
+ sendto=47
+ +0.000440
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000105
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.990293
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.004269
+ 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.001122
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000283
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.986540
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.000988
+ 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 000000e3 003e0141 0c524f4f 542d5345
+     52564552 53034e45 54000a68 6f73746d 61737465 7208494e 5445524e 4943c045
+     7726f440 00000708 00000384 00093a80 00015180.
+ +0.000665
+ sendto fd=4 addr=172.18.45.6:53
+     31270100 00010000 00000000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790864 6176656e 616e7408 67726565 6e656e64 036f7267 02756b00
+     00010001.
+ sendto=68
+ +0.000576
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000106
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.985247
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.001800
+ 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 0000016b 003e0141 0c524f4f 542d5345
+     52564552 53034e45 54000a68 6f73746d 61737465 7208494e 5445524e 4943c045
+     7726f440 00000708 00000384 00093a80 00015180.
+ +0.000671
+ sendto fd=4 addr=172.18.45.6:53
+     31280100 00010000 00000000 05747275 6e780474 65737403 69776a0a 72656c61
+     74697669 74790864 6176656e 616e7408 67726565 6e656e64 036f7267 02756b00
+     00010001.
+ sendto=68
+ +0.000550
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000105
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.984341
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.002209
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31248583 00010000 00010000 04746573 74036977 6a0a7265 6c617469 76697479
+     08646176 656e616e 74086772 65656e65 6e64036f 72670275 6b000001 00010867
+     7265656e 656e6403 6f726702 756b0000 06000100 01518000 3704646e 73300665
+     6c6d6169 6c02636f c04b0872 69636861 72646b06 63686961 726bc03e 7726f0bf
+     00007080 00001c20 00093a80 00015180.
+ +0.000817
+ sendto fd=4 addr=172.18.45.6:53
+     31290100 00010000 00000000 04746573 74036977 6a0a7265 6c617469 76697479
+     08677265 656e656e 64036f72 6702756b 00000100 01.
+ sendto=53
+ +0.000476
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000105
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.982091
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.001955
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31258583 00010000 00010000 056e6577 73780864 6176656e 616e7408 67726565
+     6e656e64 036f7267 02756b00 00010001 08677265 656e656e 64036f72 6702756b
+     00000600 01000151 80003704 646e7330 06656c6d 61696c02 636fc03d 08726963
+     68617264 6b066368 6961726b c0307726 f0bf0000 70800000 1c200009 3a800001
+     5180.
+ +0.000729
+ sendto fd=4 addr=172.18.45.6:53
+     312a0100 00010000 00000000 056e6577 73780864 6176656e 616e7400 00010001.
+ sendto=32
+ +0.000394
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000109
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.978904
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.005814
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31268580 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.001125
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000258
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.981536
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.001427
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31278583 00010000 00010000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790864 6176656e 616e7408 67726565 6e656e64 036f7267 02756b00
+     00010001 08677265 656e656e 64036f72 6702756b 00000600 01000151 80003704
+     646e7330 06656c6d 61696c02 636fc051 08726963 68617264 6b066368 6961726b
+     c0447726 f0bf0000 70800000 1c200009 3a800001 5180.
+ +0.000823
+ sendto fd=4 addr=172.18.45.6:53
+     312b0100 00010000 00000000 05747275 6e630474 65737403 69776a0a 72656c61
+     74697669 74790867 7265656e 656e6403 6f726702 756b0000 010001.
+ sendto=59
+ +0.000507
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000106
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.981820
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.002135
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31288583 00010000 00010000 05747275 6e780474 65737403 69776a0a 72656c61
+     74697669 74790864 6176656e 616e7408 67726565 6e656e64 036f7267 02756b00
+     00010001 08677265 656e656e 64036f72 6702756b 00000600 01000151 80003704
+     646e7330 06656c6d 61696c02 636fc051 08726963 68617264 6b066368 6961726b
+     c0447726 f0bf0000 70800000 1c200009 3a800001 5180.
+ +0.000844
+ 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.000505
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000103
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.981768
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.001673
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     31298580 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 00120000 0e100000 00780064 c8000000
+     003c.
+ +0.000726
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000167
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.982555
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.001681
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312a8583 00010000 00010000 056e6577 73780864 6176656e 616e7400 00010001
+     00000600 01000000 af003e01 410c524f 4f542d53 45525645 5253034e 4554000a
+     686f7374 6d617374 65720849 4e544552 4e4943c0 3a7726f4 40000007 08000003
+     8400093a 80000151 80.
+ +0.000598
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000116
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.990016
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.004585
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+     312b8580 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
+     1200000e 10000000 780064c8 00000000 3c.
+ +0.000786
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000146
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.988070
+ select=1 rfds=[4] wfds=[] efds=[]
+ +0.002234
+ 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
+     1200000e 10000000 780064c8 00000000 3c.
+ +0.000780
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ +0.000120
+ close fd=4
+ close=OK
+ +0.000181
diff --git a/regress/case-ndotsbad.err b/regress/case-ndotsbad.err
new file mode 100644 (file)
index 0000000..9050db4
--- /dev/null
@@ -0,0 +1 @@
+adns failure: init: code 22
diff --git a/regress/case-ndotsbad.out b/regress/case-ndotsbad.out
new file mode 100644 (file)
index 0000000..b980b59
--- /dev/null
@@ -0,0 +1,3 @@
+adns debug: using nameserver 172.18.45.6
+adns: <supplied configuration text>:4: option `ndots:X' malformed or has bad value
+rc=2
diff --git a/regress/case-ndotsbad.sys b/regress/case-ndotsbad.sys
new file mode 100644 (file)
index 0000000..56d5877
--- /dev/null
@@ -0,0 +1,2 @@
+ndotsbad
+:1 5/news.davenant.greenend.org.uk
index 67db3df846404c68b96b4f6919dedc4b66550034..6953cea6d403782eb8aaf90506c47ce7aa29439c 100644 (file)
@@ -2,3 +2,4 @@ adns debug: using nameserver 172.18.45.6
 chiark.greenend.org.uk flags 0 type 1 A(-) submitted
 chiark.greenend.org.uk flags 0 type A(-): OK; nrrs=1; cname=$; owner=$; ttl=86400
  195.224.76.132
 chiark.greenend.org.uk flags 0 type 1 A(-) submitted
 chiark.greenend.org.uk flags 0 type A(-): OK; nrrs=1; cname=$; owner=$; ttl=86400
  195.224.76.132
+rc=0
index 67db3df846404c68b96b4f6919dedc4b66550034..6953cea6d403782eb8aaf90506c47ce7aa29439c 100644 (file)
@@ -2,3 +2,4 @@ adns debug: using nameserver 172.18.45.6
 chiark.greenend.org.uk flags 0 type 1 A(-) submitted
 chiark.greenend.org.uk flags 0 type A(-): OK; nrrs=1; cname=$; owner=$; ttl=86400
  195.224.76.132
 chiark.greenend.org.uk flags 0 type 1 A(-) submitted
 chiark.greenend.org.uk flags 0 type A(-): OK; nrrs=1; cname=$; owner=$; ttl=86400
  195.224.76.132
+rc=0
index 02b448eb77c26c633f8da4a1309fa6877916f0c6..575646dbdd8c88b3b7ca2e21c27f9f57e2d42d26 100644 (file)
@@ -5,3 +5,4 @@ adns debug: using nameserver 172.18.45.6
  "A.ROOT-SERVERS.NET" "hostmaster@INTERNIC.NET" 1999041600 1800 900 604800 86400
 . flags 1 type SOA(822): OK; nrrs=1; cname=$; owner=$; ttl=57210
  "A.ROOT-SERVERS.NET" "hostmaster@INTERNIC.NET" 1999041600 1800 900 604800 86400
  "A.ROOT-SERVERS.NET" "hostmaster@INTERNIC.NET" 1999041600 1800 900 604800 86400
 . flags 1 type SOA(822): OK; nrrs=1; cname=$; owner=$; ttl=57210
  "A.ROOT-SERVERS.NET" "hostmaster@INTERNIC.NET" 1999041600 1800 900 604800 86400
+rc=0
index 68a7bde9b81e72b296679a40e18c03d56f701bff..ba426f15c99cc756e1ec06e213fce535ed3be817 100644 (file)
@@ -124,3 +124,4 @@ adns debug: reply not found, id 3139, query owner  (NS=172.18.45.6)
 . flags 1 type SOA(822): OK; nrrs=1; cname=$; owner=$; ttl=46580
  "A.ROOT-SERVERS.NET" "hostmaster@INTERNIC.NET" 1999041600 1800 900 604800 86400
 . flags 1 type RP(822): No such data; nrrs=0; cname=$; owner=$; ttl=598
 . flags 1 type SOA(822): OK; nrrs=1; cname=$; owner=$; ttl=46580
  "A.ROOT-SERVERS.NET" "hostmaster@INTERNIC.NET" 1999041600 1800 900 604800 86400
 . flags 1 type RP(822): No such data; nrrs=0; cname=$; owner=$; ttl=598
+rc=0
index becc759a35074c6db71f7ad305dca96b7152500a..35e0367f040098811b9024d1fbfdb05bc8b67780 100644 (file)
@@ -11,3 +11,4 @@ news flags 1 type A(-): OK; nrrs=1; cname=davenant.relativity.greenend.org.uk; o
  172.18.45.6
 chiark flags 1 type A(-): OK; nrrs=1; cname=$; owner=$; ttl=86400
  195.224.76.132
  172.18.45.6
 chiark flags 1 type A(-): OK; nrrs=1; cname=$; owner=$; ttl=86400
  195.224.76.132
+rc=0
index 79641fd216b92412fae02b01f68ab261d2ae8c1f..5fb6b5135b94f4512afd5e16c1e0b169da9d079e 100644 (file)
@@ -2,3 +2,4 @@ adns debug: using nameserver 172.18.45.6
 news.davenant flags 1 type 1 A(-) submitted
 news.davenant flags 1 type A(-): OK; nrrs=1; cname=davenant.relativity.greenend.org.uk; owner=$; ttl=584
  172.18.45.6
 news.davenant flags 1 type 1 A(-) submitted
 news.davenant flags 1 type A(-): OK; nrrs=1; cname=davenant.relativity.greenend.org.uk; owner=$; ttl=584
  172.18.45.6
+rc=0
index f07f9bc7e29feeb906427100f9d67da7f7178d1a..a3f7495ed0b3c80b611f57be01ea3fc2dc0cfe9a 100644 (file)
@@ -1,3 +1,4 @@
 adns debug: using nameserver 172.18.45.36
 chiark.greenend.org.uk flags 0 type 1 A(-) submitted
 chiark.greenend.org.uk flags 0 type A(-): DNS query timed out; nrrs=0; cname=$; owner=$; ttl=604770
 adns debug: using nameserver 172.18.45.36
 chiark.greenend.org.uk flags 0 type 1 A(-) submitted
 chiark.greenend.org.uk flags 0 type A(-): DNS query timed out; nrrs=0; cname=$; owner=$; ttl=604770
+rc=0
index 5882fcd1e5e241a8f2be5c68d30aee5d757ef976..bd70e05ce74a252135090a1e3c8401592e4bed9c 100644 (file)
@@ -1,3 +1,4 @@
 adns debug: using nameserver 172.18.45.6
 trunc.test.iwj.relativity.greenend.org.uk flags 0 type 1 A(-) submitted
 trunc.test.iwj.relativity.greenend.org.uk flags 0 type A(-): No such data; nrrs=0; cname=$; owner=$; ttl=60
 adns debug: using nameserver 172.18.45.6
 trunc.test.iwj.relativity.greenend.org.uk flags 0 type 1 A(-) submitted
 trunc.test.iwj.relativity.greenend.org.uk flags 0 type A(-): No such data; nrrs=0; cname=$; owner=$; ttl=60
+rc=0
diff --git a/regress/init-ndots.text b/regress/init-ndots.text
new file mode 100644 (file)
index 0000000..099c2ee
--- /dev/null
@@ -0,0 +1,4 @@
+nameserver 172.18.45.6
+sortlist 127.0.0.1/32 172.18.45.0/28 172.18.45.0/24
+search davenant.greenend.org.uk greenend.org.uk
+options ndots:3
diff --git a/regress/init-ndotsbad.text b/regress/init-ndotsbad.text
new file mode 100644 (file)
index 0000000..2045821
--- /dev/null
@@ -0,0 +1,4 @@
+nameserver 172.18.45.6
+sortlist 127.0.0.1/32 172.18.45.0/28 172.18.45.0/24
+search davenant.greenend.org.uk greenend.org.uk
+options ndots:X
index 5a8bbed5e27c67480ad589a7f49d7ffc9f05ff83..81cd024fe6b6bc7e6fd2af7d95615b66aaa7af91 100755 (executable)
@@ -24,12 +24,7 @@ ADNS_TEST_OUT_FD=3 3>>"$case.sys" >"$case.out" 2>"$case.err" </dev/null \
 rc=$?
 set -e
 
 rc=$?
 set -e
 
+echo "rc=$rc" >>$case.out
+
 egrep . -- "$case.err" "$case.out"
 echo "exit status: $rc"
 egrep . -- "$case.err" "$case.out"
 echo "exit status: $rc"
-
-if test $rc = 0
-then
-       echo "test created ok"
-fi
-
-exit $rc
index a9ec3ce627d999c43929dd5e23215111ad59509b..ce6b2831578cf5b934181745d488fec0ed0d888a 100755 (executable)
@@ -20,16 +20,11 @@ ADNS_TEST_REPORT_FD=3 3>>"$ocase.report" >"$ocase.out" 2>"$ocase.err" \
 rc=$?
 set -e
 
 rc=$?
 set -e
 
-if test $rc != 0
-then
-       egrep . -- "$ocase.report" "$ocase.out" "$ocase.err"
-       echo >&2 "FAILED $case - EXIT STATUS $rc"
-       exit 2
-fi
+echo "rc=$rc" >>$ocase.out
 
 for part in out err
 do
 
 for part in out err
 do
-       if diff -- "$case.$part" "$ocase.$part"
+       if diff -u -- "$case.$part" "$ocase.$part"
        then
                :
        else
        then
                :
        else
index 1b81da1fb07577c29b176d8cdf839d09c5670a40..6393f0389d5921d3b8f87b22f6b1db6de685cdcc 100644 (file)
@@ -24,6 +24,7 @@
 #include <stdlib.h>
 #include <errno.h>
 #include <string.h>
 #include <stdlib.h>
 #include <errno.h>
 #include <string.h>
+#include <limits.h>
 #include <unistd.h>
 #include <fcntl.h>
 
 #include <unistd.h>
 #include <fcntl.h>
 
@@ -153,7 +154,7 @@ static void ccf_sortlist(adns_state ads, const char *fn, int lno, const char *bu
       continue;
     }
     
       continue;
     }
     
-    memcpy(tbuf,word,l);
+    memcpy(tbuf,word,l); tbuf[l]= 0;
     slash= strchr(tbuf,'/');
     if (slash) *slash++= 0;
     
     slash= strchr(tbuf,'/');
     if (slash) *slash++= 0;
     
@@ -204,8 +205,29 @@ static void ccf_sortlist(adns_state ads, const char *fn, int lno, const char *bu
 }
 
 static void ccf_options(adns_state ads, const char *fn, int lno, const char *buf) {
 }
 
 static void ccf_options(adns_state ads, const char *fn, int lno, const char *buf) {
+  const char *word;
+  char *ep;
+  unsigned long v;
+  int l;
+
   if (!buf) return;
   if (!buf) return;
-  adns__diag(ads,-1,0,"warning - `options' ignored fixme");
+
+  while (nextword(&buf,&word,&l)) {
+    if (l==5 && !memcmp(word,"debug",5)) {
+      ads->iflags |= adns_if_debug;
+      continue;
+    }
+    if (l>=6 && !memcmp(word,"ndots:",6)) {
+      v= strtoul(word+6,&ep,10);
+      if (l==6 || ep != word+l || v > INT_MAX) {
+       configparseerr(ads,fn,lno,"option `%.*s' malformed or has bad value",l,word);
+       continue;
+      }
+      ads->searchndots= v;
+      continue;
+    }
+    adns__diag(ads,-1,0,"%s:%d: unknown option `%.*s'", fn,lno, l,word);
+  }
 }
 
 static void ccf_clearnss(adns_state ads, const char *fn, int lno, const char *buf) {
 }
 
 static void ccf_clearnss(adns_state ads, const char *fn, int lno, const char *buf) {