la5nta / pat

A cross-platform Winlink client written in Go
https://getpat.io
MIT License
488 stars 86 forks source link

winmor: Unexpected EOF #20

Closed martinhpedersen closed 8 years ago

martinhpedersen commented 8 years ago

When two Pat clients have a winmor P2P session, the client that does not send FQ will not receive it before the winmor connection ends.

According to the FBB protocol spesification a node should disconnect after sending the FQ:

If the other side has no message (after receiving an FF), it sends a line:

   FQ

and disconnects.

My guess is that the WINMOR TNC does not flush it's buffer before sending the DISC frame, the resulting being that "FQ" never reaches the other node.

One way of fixing this may be to wait until the out buffer in transport/winmor is empty before sending the DISCONNECT command.

martinhpedersen commented 8 years ago

Needs some more testing, but initial tests are promising: https://github.com/la5nta/wl2k-go/pull/37

martinhpedersen commented 8 years ago

Not pulled yet