send_all without mutex? #43
-
Maybe very trivial: Going through the code, it is not obvious to me how without locking a (client specific?) mutex in If this happens, there is no guarantee of order of Am I missing something? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hi @iyer-arvind, I think you are right. If Please let me know if I understand your question correctly so I can push a fix as soon as possible ;-). |
Beta Was this translation helpful? Give feedback.
Hi @iyer-arvind,
It is a good question. I've never thought about it. You mean two or more messages from two or more threads to the same client, right?
I think you are right. If
send
(withinsend_all
) cannot send the entire frame at once, there may be a race condition between multiple sends fighting over a single fd/client.Please let me know if I understand your question correctly so I can push a fix as soon as possible ;-).