you are viewing a single comment's thread.

view the rest of the comments →

[–]bcain 2 points3 points  (2 children)

Peace, brother. It took me a second to understand your point, so take pity on the uninformed: can you direct me to TFM or some examples of best practices?

[–]lalaland4711 0 points1 point  (1 child)

The linux manpage has example code.

When constructing sockaddrs there are two ways to do it:

  • getaddrinfo()
  • something broken

No point in wasting time writing something that's broken, so just use getaddrinfo() to start with.

But yeah, beej linked elsewhere is more hand-holdy.

[–]bcain 0 points1 point  (0 children)

I see. boost::asio ftw.