I am browsing the man pages to find out how to create TCP/IP connections with the socket-,
connect-, bind-, listen- and accept- functions, but could not find the information I
needed from the corresponding man pages. (SuSE 9.1)
Could SuSE please include a reference to ip(7) and/or tcp(7) in the description of the
'protocol' argument in socket(2)?
Could SuSE please resolve the conflicting information between getprotoent(3) and
ip(7)/tcp(7) on how to get the protocol number? Ip(7)/tcp(7) says 'protocol'
should be either 0 or the macro IPPROTO_TCP, while socket(2) says 'protocol'
should be gotten from the getprotoent(3) function call (which reads /etc/protocols). I
would very much like to use a header file's macro IPPROTO_TCP instead of fetching a
world-constant number from /etc/protocols. And it is the macros that are documented in
Steven's UNIX Network Programming :-).
Could SuSE please include a reference to ip(7)/tcp(7) in the description of the
'const struct sockaddr *serv_addr' argument in connect(2)? The text "Each
communications space interprets the serv_addr parameter in its own way." is not very
informative. How about making a paragraph based on the following from bind(2): "The
rules used in name binding vary between address families. Consult the manual entries in
Section 7 for detailed information. For AF_INET see ip(7), ...".
Software Developer, EDB
+47 4789 8062