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

etcdmain: check error before assigning peer transport #3378

Merged
merged 1 commit into from
Aug 26, 2015

Conversation

yichengq
Copy link
Contributor

Or it may panic when new transport fails, e.g., TLS info is invalid.

example when providing nonexistant TLS info:

22:06:00 proxy | panic: runtime error: invalid memory address or nil pointer dereference
22:06:00 proxy | [signal 0xb code=0x1 addr=
22:06:00 proxy | 0x80 pc=0x660bf]
22:06:00 proxy | goroutine 1 [running]:
22:06:00 proxy | github.com/coreos/etcd/etcdmain.startProxy(0x820b1a900, 0x0, 0x0)
22:06:00 proxy |    /Users/unihorn/gopath/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/etcdmain/etcd.go:317 +0x22f

Or it may panic when new transport fails, e.g., TLS info is invalid.
@xiang90
Copy link
Contributor

xiang90 commented Aug 26, 2015

LGTM

yichengq added a commit that referenced this pull request Aug 26, 2015
etcdmain: check error before assigning peer transport
@yichengq yichengq merged commit 45bb880 into etcd-io:master Aug 26, 2015
@yichengq yichengq deleted the set-late branch August 26, 2015 05:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants