[Python-bugs-list] TCP_NODELAY not found in socketmodule (PR#182)
akuchlin@mems-exchange.org
akuchlin@mems-exchange.org
Wed, 12 Jan 2000 17:12:25 -0500 (EST)
Full_Name: A.M. Kuchling
Version: CVS version
OS: Solaris 2.6
Submission from: amarok.cnri.reston.va.us (132.151.7.26)
I wanted to use the TCP_NODELAY socket option, but it wasn't found in the
socket
module, even though socketmodule.c contains:
#ifdef TCP_NODELAY
insint(d, "TCP_NODELAY", TCP_NODELAY);
#endif
"man tcp" on Solaris says that TCP_NODELAY is defined in netinet/tcp.h,
and the Open Groups Unix98 spec agrees
(http://www.opengroup.org/onlinepubs/009619199/ninettcp.htm).
socketmodule.c doesn't include that header file.
Fix: #include <netinet/tcp.h> in socketmodule.c.
But are there Unix platforms which don't
have that header, and will break? (Perhaps the configure script
could check for it.)