mirror of
https://github.com/golang/go
synced 2024-11-25 13:57:57 -07:00
http request URI should never be empty
R=rsc, adg CC=golang-dev https://golang.org/cl/217071
This commit is contained in:
parent
e198c8e66c
commit
0485a999ff
@ -167,7 +167,7 @@ func (req *Request) Write(w io.Writer) os.Error {
|
|||||||
host = req.URL.Host
|
host = req.URL.Host
|
||||||
}
|
}
|
||||||
|
|
||||||
uri := urlEscape(req.URL.Path, false)
|
uri := valueOrDefault(urlEscape(req.URL.Path, false), "/")
|
||||||
if req.URL.RawQuery != "" {
|
if req.URL.RawQuery != "" {
|
||||||
uri += "?" + req.URL.RawQuery
|
uri += "?" + req.URL.RawQuery
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user