]> git.ipfire.org Git - thirdparty/unbound.git/commitdiff
tests need forwarding mode enabled.
authorWouter Wijngaards <wouter@nlnetlabs.nl>
Thu, 24 May 2007 13:41:30 +0000 (13:41 +0000)
committerWouter Wijngaards <wouter@nlnetlabs.nl>
Thu, 24 May 2007 13:41:30 +0000 (13:41 +0000)
git-svn-id: file:///svn/unbound/trunk@337 be551aaa-1e26-0410-a405-d3ace91eadb9

14 files changed:
daemon/worker.c
doc/Changelog
iterator/iter_hints.h
iterator/iterator.c
testdata/fwd.rpl
testdata/fwd_cached.rpl
testdata/fwd_error.rpl
testdata/fwd_lrudrop.rpl
testdata/fwd_notcached.rpl
testdata/fwd_timeout.rpl
testdata/fwd_two.rpl
testdata/rrset_rettl.rpl
testdata/rrset_untrusted.rpl
testdata/rrset_updated.rpl

index 908939583acefe51382f40de376b93f914a57c29..5824171e00e109dbdcc1fd7c25cb2b3c4e9f50ce 100644 (file)
@@ -196,8 +196,8 @@ worker_process_query(struct worker* worker, struct work_query* w,
        }
        /* request done */
        if(s == module_error) {
-               qstate_free(worker, qstate);
                replyerror(LDNS_RCODE_SERVFAIL, w);
+               qstate_free(worker, qstate);
                return;
        }
        if(s == module_finished) {
index b7178909f1139db1ddae140c6c60138d54fe56fb..3a089a518ab2d8efbcbca8bdc0822a3cdf5c4f44 100644 (file)
@@ -3,6 +3,7 @@
        - iterator forwarder feature separated out.
        - iterator hints stub code, config file stub code, so that first
          testing can proceed locally.
+       - replay tests now have config option to enable forwarding mode.
 
 23 May 2007: Wouter
        - outside network does precise timers for roundtrip estimates for rtt
index 6b8d106e7dbc0b10dd4a999027645b24d0d1dd72..36d01b00d13dd916542e829ed1c40dabf3901b0f 100644 (file)
@@ -117,10 +117,11 @@ struct delegpt* hints_lookup_root(struct iter_hints* hints, uint16_t qclass);
  * for this qname/qclass, determine if this combination indicates that a
  * stub hint exists and must be primed.
  *
- * @param qname The qname that generated the delegation point.
- * @param qclass The qclass that generated the delegation point.
- * @param dp The cache generated delegation point.
- * @return A priming delegation point if there is a stub hint that must
+ * @param hints: hint storage.
+ * @param qname: The qname that generated the delegation point.
+ * @param qclass: The qclass that generated the delegation point.
+ * @param dp: The cache generated delegation point.
+ * @return: A priming delegation point if there is a stub hint that must
  *         be primed, otherwise null.
  */
 struct delegpt* hints_lookup_stub(struct iter_hints* hints, 
index 0dc26bdb768a8bc0d35509313b435f320c9bd7b0..2e425761e3b44f82cb73cdc74de2df0298a85500 100644 (file)
@@ -201,7 +201,7 @@ perform_forward(struct module_qstate* qstate, enum module_ev event, int id,
                        qstate->ext_state[id] = module_error;
                return;
        }
-       log_err("bad event for iterator");
+       log_err("bad event for iterator[forwarding]");
        qstate->ext_state[id] = module_error;
 }
 
@@ -222,6 +222,8 @@ iter_operate(struct module_qstate* qstate, enum module_ev event, int id,
                perform_forward(qstate, event, id, outbound);
                return;
        }
+       log_err("bad event for iterator");
+       qstate->ext_state[id] = module_error;
 }
 
 /** iterator cleanup query state */
index a9c65df24299773d47d8dad95be23580f413fa87..85212f11b027a0f140db2a98b86bb93c21f09a5f 100644 (file)
@@ -1,5 +1,6 @@
 ; This is a comment.
 ; config options go here.
+server: forward-to: "127.0.0.1"
 CONFIG_END
 
 SCENARIO_BEGIN Sample of a valid query
index 9408730b0bb7cdf596c48611a725a8e46d1b6a8a..001783e6e48404354fdd45cd6d88fd98a80412c6 100644 (file)
@@ -1,5 +1,6 @@
 ; This is a comment.
 ; config options go here.
+server:        forward-to: "127.0.0.1"
 CONFIG_END
 
 SCENARIO_BEGIN Query receives answer from the cache
index 55f9e87fd30c9df041d5f7750d3b74198ff6a7f3..44fd6a277ab25fc28c863237595dcac35c632903 100644 (file)
@@ -1,4 +1,5 @@
 ; config options go here.
+server:        forward-to: "127.0.0.1"
 CONFIG_END
 SCENARIO_BEGIN Forwarder and an error happens on server query.
 STEP 1 QUERY
index de393e61490071a0c62934c62830ab54afd13397..06f7c2c9e9169c0855cea1438b800f17487f4d5a 100644 (file)
@@ -4,6 +4,7 @@
 server:
        msg-cache-size: 1 # one whole byte!
        msg-cache-slabs: 1
+       forward-to: "127.0.0.1"
 CONFIG_END
 
 SCENARIO_BEGIN Old answer is dropped from the cache
index 3c771448c4cc261c08013af53edb65df4c48ae86..1a2cd812704ff62bce5a6fa9e9178714e026260e 100644 (file)
@@ -5,6 +5,7 @@
 ; here config file options:
 server:
        msg-cache-size: 1024
+       forward-to: "127.0.0.1"
 CONFIG_END
 
 SCENARIO_BEGIN Query receives answer not from the cache
index 27678c3de1ed6137cded5a5f6a2d67ec2451ba07..979fd380235de8aa1ecf7a7ef852dae5c98bbd9d 100644 (file)
@@ -1,4 +1,5 @@
 ; config options go here.
+server: forward-to: "127.0.0.1"
 CONFIG_END
 SCENARIO_BEGIN Forwarder and a timeout happens on server query.
 STEP 1 QUERY
index 2e1354d067c2497cdd9ccb4a486f372c61d68681..7142d66390d757ad6de73eb4576b41b8951f6a22 100644 (file)
@@ -1,6 +1,7 @@
 ; config options go here.
 server:
        num-queries-per-thread: 1
+       forward-to: "127.0.0.1"
 CONFIG_END
 SCENARIO_BEGIN Sample of a valid query
 
index 8177dcad1eeee090d658e2c9b1252d04fa78fe09..6ececeb7a16f6cf25da50ade00e457fb5e79bad2 100644 (file)
@@ -1,5 +1,6 @@
 ; This is a comment.
 ; config options go here.
+server:        forward-to: "127.0.0.1"
 CONFIG_END
 
 SCENARIO_BEGIN RRset TTL is updated from message.
index 868ea113abb5825fb0b4bd0e785c71fa307f3064..b044f992cda5d82b9feef61f3bf9ac8130346ce2 100644 (file)
@@ -1,5 +1,6 @@
 ; This is a comment.
 ; config options go here.
+server:        forward-to: "127.0.0.1"
 CONFIG_END
 
 SCENARIO_BEGIN Untrusted rrset not used for update
index 146c287be4457c473cb3f3f69252897bc7993474..da4135882763c068d30fb69703de3da5da99d9a9 100644 (file)
@@ -1,5 +1,6 @@
 ; This is a comment.
 ; config options go here.
+server:        forward-to: "127.0.0.1"
 CONFIG_END
 
 SCENARIO_BEGIN RRset is updated from other message that passes by.