Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

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
add comment

1 Answer 1

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
add comment

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.