[riot-notifications] [RIOT-OS/RIOT] sock_dtls: add timeout to sock_dtls_send and add sock_dtls_session_init (#14043)
notifications at github.com
Tue May 19 12:55:14 CEST 2020
I pushed a "fix" for the hang problem but that's causing the client to always print 0 received bytes. I know why this happens but I think our main issue is the return value of `sock_dtls_recv()`.
When the function returns 0, the server doesn't know if it's because a new client is connected or a client sent an empty message. In the test that you did, the server ignores any message with length 0 causing the client to wait indefinitely for the echo message from the server.
I think we need a way to differentiate that a new client connected and empty messages. Is there any other value that we can use for the return in `sock_dtls_recv()` to indicate that a new client is connected?
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the notifications