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: data race and nil pointer deref #7595

Closed
augustoroman opened this issue Mar 20, 2014 · 5 comments
Closed

net/http: data race and nil pointer deref #7595

augustoroman opened this issue Mar 20, 2014 · 5 comments

Comments

@augustoroman
Copy link
Contributor

I'm getting a reliable crash from a nil pointer dereference deep in the net/http
package, immediately after some data races.  This occurs for a particular, large request
(112MB) that crashes the backend server and subsequently kills the proxy with the nil
pointer deference.

Attached are race logs and panic stack traces from go 1.2 and 1.2.1.  The core proxy
code is also attached.

Attachments:

  1. go1.2 race and stack trace.txt (35107 bytes)
  2. go1.2.1 race and stack trace.txt (36204 bytes)
  3. proxy.go (6067 bytes)
@augustoroman
Copy link
Contributor Author

Comment 1:

update: It's not actually crashing the backend server.  The backend (node.js) server is
limiting the size of the data read from the request.  The proxy server reliably crashes
anytime the request size exceeds the backend limit.

@augustoroman
Copy link
Contributor Author

Comment 3:

Attached is a small repro case exhibiting this behavior.
Unzip and run "./run.sh" -- that runs a node server, a minimal go proxy, and executes a
large request through the proxy that crashes the proxy.

Attachments:

  1. repro.zip (2146 bytes)

@bradfitz
Copy link
Contributor

Comment 4:

I'm pretty sure this is a duplicate of issue #6995.
Please try Go tip (not yet recommended for production, but should/might work) and see if
you can still reproduce.

Status changed to WaitingForReply.

@augustoroman
Copy link
Contributor Author

Comment 5:

Yes, it works on tip.

@bradfitz
Copy link
Contributor

Comment 6:

Status changed to Duplicate.

Merged into issue #6995.

@golang golang locked and limited conversation to collaborators Jun 25, 2016
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