diff --git a/session.go b/session.go index de0c69b..778e24b 100644 --- a/session.go +++ b/session.go @@ -207,6 +207,12 @@ func (s *Session) Close() error { } } +// CloseChan can be used by someone who wants to be notified immediately when this +// session is closed +func (s *Session) CloseChan() <-chan struct{} { + return s.die +} + // notifyBucket notifies recvLoop that bucket is available func (s *Session) notifyBucket() { select {