Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Porting an application from RHEL5 to Solaris 8. setsockopt(kinet[inst_id].sock_no,SOL_TCP,TCP_NODELAY,&option,sizeof(option)); causes a compile error because SOL_TCP is not defined in /usr/include/sys/socket.h in Solaris 8, as it is in RHEL5.

share|improve this question

SOL_TCP is not portable, but it looks like you get it to working on Solaris and others by adding this:

#ifndef SOL_TCP
#define SOL_TCP IPPROTO_TCP
#endif
share|improve this answer
    
Verified. Thank you! – Carl Feb 28 '11 at 13:35

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.