func (srv *Server) ListenAndServe() error {
	addr := srv.Addr
	if addr == "" {
		addr = ":2775"
	}
	ln, err := net.Listen("tcp", addr)
	if err != nil {
		return err
	}
	return srv.Serve(tcpKeepAliveListener{ln.(*net.TCPListener)})
}
ListenAndServe starts server listening. Blocking function.
package smpp
import (
	"context"
	"net"
	"sync"
	"time"
)
type tcpKeepAliveListener struct {
	*net.TCPListener
}
func (ln tcpKeepAliveListener) Accept() (c net.Conn, err error) {
	tc, err := ln.AcceptTCP()
	if err != nil {
		return
	}
	tc.SetKeepAlive(true)
	tc.SetKeepAlivePeriod(3 * time.Minute)
	return tc, nil
}
type Server struct {
	Addr        string
	SessionConf *SessionConf
	wg         sync.WaitGroup
	mu         sync.Mutex
	listeners  map[net.Listener]struct{}
	doneChan   chan struct{}
	activeSess map[*Session]struct{}
}
func NewServer(addr string, conf SessionConf) *Server {
	return &Server{
		Addr:        addr,
		SessionConf: &conf,
	}
}