func (m *Multiplex) Accept() (*Stream, error) {
	select {
	case s, ok := <-m.nstreams:
		if !ok {
			return nil, errors.New("multiplex closed")
		}
		return s, nil
	case <-m.closed:
		return nil, m.shutdownErr
	}
}
func (m *Multiplex) Accept() (*Stream, error) {
	select {
	case s, ok := <-m.nstreams:
		if !ok {
			return nil, errors.New("multiplex closed")
		}
		return s, nil
	case <-m.closed:
		return nil, m.shutdownErr
	}
}
func ( m * Multiplex ) Accept ( ) ( * Stream , error ) { select { case s , ok := <- m . nstreams : if ! ok { return nil , errors . New ( " " ) } return s , nil case <- m . closed : return nil , m . shutdownErr } }
// Accept accepts the next stream from the connection.
Accept accepts the next stream from the connection .