rafthttp: streamReader roundtrip -> dial

release-2.1
Yicheng Qin 2015-03-02 13:26:48 -08:00
parent a299f68e09
commit 8ec28f27d1
1 changed files with 2 additions and 2 deletions

View File

@ -219,7 +219,7 @@ func startStreamReader(tr http.RoundTripper, u string, t streamType, from, to, c
func (cr *streamReader) run() {
for {
rc, err := cr.roundtrip()
rc, err := cr.dial()
if err != nil {
log.Printf("rafthttp: roundtripping error: %v", err)
} else {
@ -307,7 +307,7 @@ func (cr *streamReader) isWorking() bool {
return cr.closer != nil
}
func (cr *streamReader) roundtrip() (io.ReadCloser, error) {
func (cr *streamReader) dial() (io.ReadCloser, error) {
cr.mu.Lock()
u := cr.u
term := cr.msgAppTerm