Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A small mistake in http package #622

Closed
gopherbot opened this issue Feb 24, 2010 · 4 comments
Closed

A small mistake in http package #622

gopherbot opened this issue Feb 24, 2010 · 4 comments

Comments

@gopherbot
Copy link
Contributor

by Heresy.Mc:

Before filing a bug, please check whether it has been fixed since
the latest release: run "hg pull -u" and retry what you did to
reproduce the problem.  Thanks.

What steps will reproduce the problem?
1./src/pkg/http/response.go#L361
2.func (r *Response) GetHeader(key string) (value string)
3.

What is the expected output? What do you see instead?
According to the comments "GetHeader returns the value of the response 
header with the given key, and true." the GetHeader() should return two 
values. But here it returns one.

What is your $GOOS?  $GOARCH?
$GOOS=linux
$GOARCH=amd64


Which revision are you using?  (hg identify)
release.2010-02-23


Please provide any additional information below.
// GetHeader returns the value of the response header with the given 
// key, and true.  If there were multiple headers with this key, their 
// values are concatenated, with a comma delimiter.  If there were no 
// response headers with the given key, it returns the empty string and 
// false.  Keys are not case sensitive. 
func (r *Response) GetHeader(key string) (value string) { 
    value, _ = r.Header[CanonicalHeaderKey(key)] 
    return 

}
@rsc
Copy link
Contributor

rsc commented Feb 25, 2010

Comment 1:

Owner changed to a...@golang.org.

@adg
Copy link
Contributor

adg commented Mar 1, 2010

Comment 2:

Status changed to Accepted.

@adg
Copy link
Contributor

adg commented Mar 1, 2010

Comment 3:

Should be addressed by changelist 224084.

@adg
Copy link
Contributor

adg commented Mar 2, 2010

Comment 4:

This issue was closed by revision adf1e4c.

Status changed to Fixed.

@golang golang locked and limited conversation to collaborators Jun 24, 2016
@rsc rsc unassigned adg Jun 22, 2022
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants