summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorGlenn Strauss <gstrauss@gluelogic.com>2016-08-06 04:11:16 -0400
committerGlenn Strauss <gstrauss@gluelogic.com>2016-08-06 04:28:45 -0400
commit4bc06bfc0b72b92c67f21ac0dc7de7d67be73728 (patch)
tree39a0984eaf1ed53e0ebbd9be55b83881b97d012a /tests
parent1de652f40badac2d2c6c3f4d348b8c35635519e1 (diff)
downloadlighttpd1.4-4bc06bfc0b72b92c67f21ac0dc7de7d67be73728.tar.gz
lighttpd1.4-4bc06bfc0b72b92c67f21ac0dc7de7d67be73728.zip
[core] check if client half-closed TCP if POLLHUP (#2743)
Check if client half-closed TCP connection if POLLHUP is received. This more robustly handles if client called shutdown(fd, SHUT_WR). This patch reverts commit:ab05eb7c which should now be handled properly. (Time will tell.) x-ref: "1.4.40/41 mod_proxy, mod_scgi may trigger POLLHUP on *BSD,Darwin" https://redmine.lighttpd.net/issues/2743
Diffstat (limited to 'tests')
-rw-r--r--tests/LightyTest.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/LightyTest.pm b/tests/LightyTest.pm
index b975d651..129acd87 100644
--- a/tests/LightyTest.pm
+++ b/tests/LightyTest.pm
@@ -223,6 +223,7 @@ sub handle_http {
print $remote $_.$BLANK;
diag("\n<< ".$_) if $is_debug;
}
+ shutdown($remote, 1) if ($^O ne "openbsd"); # I've stopped writing data
} else {
diag("\nsending request header to ".$host.":".$self->{PORT}) if $is_debug;
foreach(@request) {