Closed
Description
What version of Go are you using (go version
)?
$ go version go version go1.15.6 linux/amd64
Does this issue reproduce with the latest release?
Yes.
What operating system and processor architecture are you using (go env
)?
go env
Output
$ go env GO111MODULE="" GOARCH="amd64" GOBIN="" GOCACHE="/home/saicops/.cache/go-build" GOENV="/home/saicops/.config/go/env" GOEXE="" GOFLAGS="" GOHOSTARCH="amd64" GOHOSTOS="linux" GOINSECURE="" GOMODCACHE="/home/saicops/.go/pkg/mod" GONOPROXY="" GONOSUMDB="" GOOS="linux" GOPATH="/home/saicops/.go" GOPRIVATE="" GOPROXY="https://goproxy.cn,direct" GOROOT="/opt/soft_ln/go" GOSUMDB="sum.golang.org" GOTMPDIR="" GOTOOLDIR="/opt/soft_ln/go/pkg/tool/linux_amd64" GCCGO="gccgo" AR="ar" CC="gcc" CXX="g++" CGO_ENABLED="1" GOMOD="" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build006094992=/tmp/go-build -gno-record-gcc-switches"
What did you do?
http.go:
package main
import (
"fmt"
"net/http"
)
func HelloHandler(w http.ResponseWriter, r *http.Request) {
fmt.Fprintf(w, "hello-world")
}
func main() {
http.HandleFunc("/", HelloHandler)
http.ListenAndServe("0.0.0.0:9999", nil)
}
go run http.go
curl http://127.0.0.1/a=1321dsfdj123414dsfsf321321nlkfdsfdsflewrpwokofdfsd...
make sure the url is longer than 4096 bytes when use wireshark capture the flow. AND THEN you won't get the response
What did you expect to see?
"hello-world"
What did you see instead?
nothing