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

net/http: lock the read-only mutex in shouldRedirect #23994

Closed
wants to merge 1 commit into from
Closed

net/http: lock the read-only mutex in shouldRedirect #23994

wants to merge 1 commit into from

Conversation

dmathieu
Copy link
Contributor

@dmathieu dmathieu commented Feb 21, 2018

Since that method uses 'mux.m', we need to lock the mutex to avoid data races.

@googlebot googlebot added the cla: yes Used by googlebot to label PRs as having a valid CLA. The text of this label should not change. label Feb 21, 2018
@gopherbot
Copy link
Contributor

This PR (HEAD: 2df4617) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/#/c/go/+/95775 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link
Contributor

Message from Gobot Gobot:

Patch Set 1:

Congratulations on opening your first change. Thank you for your contribution!

Next steps:
Within the next week or so, a maintainer will review your change and provide
feedback. See https://golang.org/doc/contribute.html#review for more info and
tips to get your patch through code review.

Most changes in the Go project go through a few rounds of revision. This can be
surprising to people new to the project. The careful, iterative review process
is our way of helping mentor contributors and ensuring that their contributions
have a lasting impact.

During May-July and Nov-Jan the Go project is in a code freeze, during which
little code gets reviewed or merged. If a reviewer responds with a comment like
R=go1.11, it means that this CL will be reviewed as part of the next development
cycle. See https://golang.org/s/release for more details.


Please don’t reply on this GitHub thread. Visit golang.org/cl/95775.
After addressing review feedback, remember to publish your drafts!

@andybons andybons changed the base branch from release-branch.go1.10 to master February 22, 2018 06:03
@andybons andybons changed the base branch from master to release-branch.go1.10 February 22, 2018 06:03
@andybons
Copy link
Member

You have to change the base branch to master instead of release-branch.go1.10

@gopherbot
Copy link
Contributor

Message from Andrew Bonventre:

Patch Set 1:

This is on the wrong branch. Please rebase onto master instead of release-branch.go1.10


Please don’t reply on this GitHub thread. Visit golang.org/cl/95775.
After addressing review feedback, remember to publish your drafts!

@dmathieu dmathieu changed the base branch from release-branch.go1.10 to master February 22, 2018 08:17
@gopherbot
Copy link
Contributor

This PR (HEAD: 0919042) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/#/c/go/+/95775 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link
Contributor

Message from Damien Mathieu:

Patch Set 2:

Patch Set 1:

This is on the wrong branch. Please rebase onto master instead of release-branch.go1.10

Sorry about that. I've rebased my PR.


Please don’t reply on this GitHub thread. Visit golang.org/cl/95775.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Brad Fitzpatrick:

Patch Set 2: Code-Review-2

Temporary -2 until this is sorted out onto the right branch. Maybe Gerritbot can't move its Gerrit branch from its PR branch moving. Andy?


Please don’t reply on this GitHub thread. Visit golang.org/cl/95775.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Brad Fitzpatrick:

Patch Set 2:

Also, it'd be nice to see a new test for this. (a test with two goroutines that fails under the race detector before, and passes with this change)


Please don’t reply on this GitHub thread. Visit golang.org/cl/95775.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

This PR (HEAD: 8cb5f3e) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/#/c/go/+/96575 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link
Contributor

Message from Brad Fitzpatrick:

Patch Set 1:

(2 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

Since that method uses 'mux.m', we need to lock the mutex to avoid data
races.
@gopherbot
Copy link
Contributor

This PR (HEAD: 163a7d4) has been imported to Gerrit for code review.

Please visit https://go-review.googlesource.com/#/c/go/+/96575 to see it.

Tip: You can toggle comments from me using the comments slash command (e.g. /comments off)
See the Wiki page for more info

@gopherbot
Copy link
Contributor

Message from Gerrit Bot:

Uploaded patch set 2: Commit message was updated.


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Gerrit Bot:

Uploaded patch set 3: Commit message was updated.


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Damien Mathieu:

Patch Set 3:

(2 comments)


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Andrew Bonventre:

Patch Set 3:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Damien Mathieu:

Patch Set 3:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Andrew Bonventre:

Patch Set 3:

(1 comment)


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Gerrit Bot:

Uploaded patch set 4: Commit message was updated.


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Brad Fitzpatrick:

Patch Set 5: Patch Set 4 was rebased


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Brad Fitzpatrick:

Patch Set 5: Run-TryBot+1 Code-Review+2


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Gobot Gobot:

Patch Set 5:

TryBots beginning. Status page: https://farmer.golang.org/try?commit=c71940a0


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

Message from Gobot Gobot:

Patch Set 5: TryBot-Result-1

1 of 17 TryBots failed:
Failed on windows-amd64-2016: https://storage.googleapis.com/go-build-log/c71940a0/windows-amd64-2016_64d53026.log

Consult https://build.golang.org/ to see whether they are new failures.


Please don’t reply on this GitHub thread. Visit golang.org/cl/96575.
After addressing review feedback, remember to publish your drafts!

@gopherbot
Copy link
Contributor

This PR is being closed because golang.org/cl/96575 has been merged.

@gopherbot gopherbot closed this Mar 2, 2018
gopherbot pushed a commit that referenced this pull request Mar 2, 2018
Since that method uses 'mux.m', we need to lock the mutex to avoid data races.

Change-Id: I998448a6e482b5d6a1b24f3354bb824906e23172
GitHub-Last-Rev: 163a7d4
GitHub-Pull-Request: #23994
Reviewed-on: https://go-review.googlesource.com/96575
Reviewed-by: Brad Fitzpatrick <[email protected]>
Run-TryBot: Brad Fitzpatrick <[email protected]>
@m90
Copy link

m90 commented Apr 30, 2018

Is there any info on which future release of go will contain this fix? I can't find it either in 1.10.2 or 1.11 milestones.

@ianlancetaylor
Copy link
Member

@m90 Note that few people read comments on GitHub pull requests. For better places to ask questions see https://golang.org/wiki/Questions .

This fix will be in the future 1.11 release.

jasonwbarnett pushed a commit to jasonwbarnett/fileserver that referenced this pull request Jul 11, 2018
Since that method uses 'mux.m', we need to lock the mutex to avoid data races.

Change-Id: I998448a6e482b5d6a1b24f3354bb824906e23172
GitHub-Last-Rev: 163a7d4942e793b328e05a7eb91f6d3fdc4ba12b
GitHub-Pull-Request: golang/go#23994
Reviewed-on: https://go-review.googlesource.com/96575
Reviewed-by: Brad Fitzpatrick <[email protected]>
Run-TryBot: Brad Fitzpatrick <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes Used by googlebot to label PRs as having a valid CLA. The text of this label should not change.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants