I need to write a chat using POLL. But in general, I do not know how to do it.

Can anyone tell?

  • one
    Why are you asking in two languages? Are you afraid they won't understand you? - 0xdb
  • Obviously, a call to poll on the server gives you an active (to which something has come) a socket (including the joining of a new member). You read the data from it and rewrite it to the others or add the socket of a new member to the socket set for poll. Just do not forget to provide the text being sent with the source login (which it must provide when it connects to your chat server) - avp

0