Code Review
/
govpp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
connection: prevent channel ID overlap
[govpp.git]
/
core
/
stream.go
diff --git
a/core/stream.go
b/core/stream.go
index
2f639b0
..
67236f1
100644
(file)
--- a/
core/stream.go
+++ b/
core/stream.go
@@
-56,7
+56,11
@@
func (c *Connection) NewStream(ctx context.Context, options ...api.StreamOption)
option(s)
}
option(s)
}
- s.channel = c.newChannel(s.requestSize, s.replySize)
+ ch, err := c.newChannel(s.requestSize, s.replySize)
+ if err != nil {
+ return nil, err
+ }
+ s.channel = ch
s.channel.SetReplyTimeout(s.replyTimeout)
// Channel.watchRequests are not started here intentionally, because
s.channel.SetReplyTimeout(s.replyTimeout)
// Channel.watchRequests are not started here intentionally, because