wait for handle message
Some checks failed
Build and Publish / BuildAndDeployAmd64 (push) Successful in 28s
Build and Publish / BuildAndDeploy (push) Has been cancelled

This commit is contained in:
matst80
2024-11-13 22:18:40 +01:00
parent 9e87351681
commit 2a7f279cd5

View File

@@ -128,6 +128,7 @@ func WaitForFrame(conn net.Conn, resultChan chan<- FrameWithPayload) error {
}
return err
}
log.Println("Checksum mismatch")
return fmt.Errorf("checksum mismatch")
}
@@ -165,7 +166,7 @@ func (l *GenericListener) HandleConnection(conn net.Conn) {
go WaitForFrame(conn, ch)
select {
case frame := <-ch:
go l.HandleFrame(conn, &frame)
l.HandleFrame(conn, &frame)
case <-time.After(MaxCallDuration):
close(ch)
log.Printf("Timeout waiting for frame\n")