summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tests/httpd8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/httpd b/tests/httpd
index 682556b..48e14ea 100644
--- a/tests/httpd
+++ b/tests/httpd
@@ -64,15 +64,15 @@ proc httpdRead { sock } {
-> data(proto) data(url) data(query) data(httpversion)]} {
set data(state) mime
httpd_log $sock Query $line
+ if {[regexp {(?:^|[\?&])delay=([^&]+)} $data(query) {} val]} {
+ fileevent $sock readable {}
+ after $val [list fileevent $sock readable [list httpdRead $sock]]
+ }
} else {
httpdError $sock 400
httpd_log $sock Error "bad first line:$line"
httpdSockDone $sock
}
- if {[regexp {(?:^|[\?&])delay=([^&]+)} $data(query) {} val]} {
- fileevent $sock readable {}
- after $val [list fileevent $sock readable [list httpdRead $sock]]
- }
return
} elseif {$data(state) == "mime"} {