service: do not use cmux if there is no http server

Signed-off-by: Adphi <philippe.adrien.nousse@gmail.com>
This commit is contained in:
Adphi 2025-03-18 13:23:34 +01:00
parent 67e1c9be8e
commit 8eb63902b0
Signed by: adphi
GPG Key ID: 46BE4062DB2397FF

View File

@ -247,7 +247,7 @@ func (s *service) start() (*errgroup.Group, error) {
}
fn := s.runWithCmux
if s.opts.withoutCmux {
if s.opts.withoutCmux || s.opts.mux == nil {
fn = s.runWithoutCmux
}