diff options
author | Aliaksandr Valialkin <valyala@gmail.com> | 2016-02-19 20:17:37 +0200 |
---|---|---|
committer | Aliaksandr Valialkin <valyala@gmail.com> | 2016-02-19 20:17:37 +0200 |
commit | 58e4dea85db1b01e95b02e105b2a0e953c52694a (patch) | |
tree | 4343ca86ceeb660a37d9d7fc7f01aff1679e5b6c /uri.go | |
parent | Allow updating request's RequestURI and Host header via Request.URI() (diff) | |
download | fasthttp-58e4dea85db1b01e95b02e105b2a0e953c52694a.tar.gz fasthttp-58e4dea85db1b01e95b02e105b2a0e953c52694a.tar.bz2 fasthttp-58e4dea85db1b01e95b02e105b2a0e953c52694a.zip |
Properly copy query arguments in URI.CopyTo
Diffstat (limited to 'uri.go')
-rw-r--r-- | uri.go | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -62,7 +62,8 @@ func (u *URI) CopyTo(dst *URI) { dst.hash = append(dst.hash[:0], u.hash...) dst.host = append(dst.host[:0], u.host...) - dst.parsedQueryArgs = false + u.queryArgs.CopyTo(&dst.queryArgs) + dst.parsedQueryArgs = u.parsedQueryArgs // fullURI and requestURI shouldn't be copied, since they are created // from scratch on each FullURI() and RequestURI() call. |