Socket programming tips in Solaris

  NanXiao        2014-05-09 23:01:03       12,102        0         

I sponsored a topic in stackoverflow.com, and hoped the programmers can share the socket programming tips in different UNIX flavors. But unfortunately, the responders are few. So I can only share my socket programming tips in Solaris at here (the Chinese version can be found there):

1. Use the following link options: "-lresolv -lnsl -lsocket";
2. Solaris doesn't provide socket options: SO_SNDTIMEO and SO_RCVTIMEO(Why does Solaris OS define SO_SNDTIMEO and SO_RCVTIMEO socket options in header file which actually not support by kernel?);
3. In SCTP programming, must call bind() before calling sctp_bindx()(sctp_bindx(Solaris sctp library) always return "Invalid argument");
4. When calling shutdown() on a listen socket, it will cause ENOTCONN error(Why shutdown a socket can't let the select() return?).

C  SOLARIS  SOCKET 

           

  RELATED


  0 COMMENT


No comment for this article.



  RANDOM FUN

Objects belong to our generation

What are you using to listen to music today? iPod, iPhone or other MP3 players? Have you ever seen the above object? Have you ever seen above music cassette tapes in real? I believe these are the objects beloging to people born in 70s and 80s. Do you know what are the connection between the above tw