code: func (p *Provider) handleSession(list net.Listener, doneCh chan struct{}) {
  	defer close(doneCh)
  	defer list.Close()
  	// Accept new connections
  	for !p.IsShutdown() {
  		conn, err := list.Accept()
  		if err != nil {
  			p.logger.Printf("[ERR] scada-client: failed to accept connection: %v", err)
  			return
  		}
  		p.logger.Printf("[DEBUG] scada-client: accepted connection")
  		go p.handleConnection(conn)
  	}
  }
docs: // handleSession is used to handle an established session