func (c *singleConn) Close() error {
	c.eventMu.Lock()
	if c.event != nil {
		evt := c.event
		c.event = nil
		defer evt.Close()
	}
	c.eventMu.Unlock()

	// close underlying connection
	return c.maconn.Close()
}
func (c *singleConn) Close() error {
	c.eventMu.Lock()
	if c.event != nil {
		evt := c.event
		c.event = nil
		defer evt.Close()
	}
	c.eventMu.Unlock()

	
	return c.maconn.Close()
}
func ( c * singleConn ) Close ( ) error { c . eventMu . Lock ( ) if c . event != nil { evt := c . event c . event = nil defer evt . Close ( ) } c . eventMu . Unlock ( ) // close underlying connection return c . maconn . Close ( ) }
// close is the internal close function, called by ContextCloser.Close
close is the internal close function called by ContextCloser . Close