Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

str2str does not always detect disconnection when waiting for NTRIP response from caster #575

Open
Jef239 opened this issue Feb 13, 2025 · 0 comments

Comments

@Jef239
Copy link

Jef239 commented Feb 13, 2025

Error in recv_nb procedure. This procedure does select and recv and returns one of three options:

ret>0 - n bytes received
ret<0 - error
ret==0 - nothing received

The arrival of FIN (disconnect) is encoded as a return of -1 with errno==0. However, if errno!=0 before the call, it is not cleared when executing recv_nb. And then the situation is treated as an error, not as a disconnect. If errno was EGAIN, then the disconnect is not detected at all.

recv_nb.patch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant