diff options
author | Nicolas PLANEL <nplanel@redhat.com> | 2019-03-20 14:14:10 +0100 |
---|---|---|
committer | Nicolas PLANEL <nplanel@redhat.com> | 2019-03-20 14:23:02 +0100 |
commit | 29e1639101b093c5f66331b0f1385564c88db1c7 (patch) | |
tree | 85869230816086ff025cb985f4818e2a1b90c0dc /core | |
parent | 6dd658f579ae4e1d9704e14380b69fe906c57ad2 (diff) |
fixup race on ch.reqChan
git.fd.io/govpp.git/core/request_handler.go:37
git.fd.io/govpp.git/core/channel.go:188
Change-Id: I5be8be5e3ca105822ea4bb3b9690938634950d78
Signed-off-by: Nicolas PLANEL <nplanel@redhat.com>
Diffstat (limited to 'core')
-rw-r--r-- | core/channel.go | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/core/channel.go b/core/channel.go index 6cb02f7..2e73917 100644 --- a/core/channel.go +++ b/core/channel.go @@ -184,10 +184,7 @@ func (ch *Channel) SetReplyTimeout(timeout time.Duration) { } func (ch *Channel) Close() { - if ch.reqChan != nil { - close(ch.reqChan) - ch.reqChan = nil - } + close(ch.reqChan) } func (req *requestCtx) ReceiveReply(msg api.Message) error { |