home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / mpgsoref.zip / MPTSPROG.INF (.txt)
OS/2 Help File  |  1998-05-08  |  394KB  |  6,662 lines

  1.  
  2. ΓòÉΓòÉΓòÉ 1. About This Book ΓòÉΓòÉΓòÉ
  3.  
  4. The MPTS Sockets Programming Reference describes the Sockets application 
  5. programming interface in an Multi-Protocol Transport Services (MPTS) 
  6. Environment for Operating System/2 Software for the Internet (TCP/IP), local 
  7. interprocess communication (Local IPC), and the NETBIOS communication domains. 
  8. This interface allows you to write distributed or client/server applications in 
  9. supported communication domains for programs to communicate across networks. 
  10.  
  11.  
  12. ΓòÉΓòÉΓòÉ 1.1. Who Should Use This Book ΓòÉΓòÉΓòÉ
  13.  
  14. This book is for application programmers who want to write socket applications 
  15. to work with MPTS.  You should also be familiar with the OS/2 operating system 
  16. and know multitasking operating system concepts. 
  17.  
  18.  
  19. ΓòÉΓòÉΓòÉ 1.2. How This Book Is Organized ΓòÉΓòÉΓòÉ
  20.  
  21. This book contains the following topics: 
  22.  
  23.      Sockets General Programming Information provides an introduction to MPTS 
  24.       and describes general concepts for writing socket applications. 
  25.      Sockets in the Internet Domain provides specific information for the use 
  26.       of sockets in the internet communication domain. 
  27.      Sockets over Local IPC provides specific information for the use of 
  28.       sockets using local interprocess communication. 
  29.      Sockets over NetBIOS provides specific information for the use of sockets 
  30.       in the NetBIOS communication domain. 
  31.      Protocol-Independent C Sockets API provides descriptions and programming 
  32.       details for the protocol-independent sockets API. 
  33.      TCP/IP Network Utility Routines provides descriptions and programming 
  34.       details for the TCP/IP network utility routines. 
  35.  
  36.  
  37. ΓòÉΓòÉΓòÉ 1.3. Where to Find More Information ΓòÉΓòÉΓòÉ
  38.  
  39. The following books or online references are suggested for additional reading 
  40. and information. 
  41.  
  42. At your local bookstore: 
  43.  
  44.      TCP/IP Illustrated, Volume 1: The Protocols, W. Richard Stevens, Addison 
  45.       Wesley, 1994 
  46.  
  47.      TCP/IP Illustrated, Volume 2: The Implementation, Gary R. Wright and W. 
  48.       Richard Stevens, Addison Wesley, 1995 
  49.  
  50.      UNIX Network Programming, W. Richard Stevens, Prentice Hall, Englewood 
  51.       Cliffs, New Jersey, 1990 
  52.  
  53.      The C Programming Language: 2nd edition, Brian Kernighan and Dennis 
  54.       Ritchie, Prentice Hall, 1988 
  55.  
  56.      IBM TCP/IP Tutorial and Technical Overview 
  57.  
  58.      Internetworking with TCP/IP Volume I: Principles, Protocols, and 
  59.       Architectures 
  60.  
  61.      Internetworking with TCP/IP Volume II: Implementation and Internals 
  62.  
  63.      Introducing IBM's TCP/IP Products for OS/2, VM and MMVS 
  64.  
  65.      IBM TCP/IP Version 3.1 for OS/2: Programmer's Reference 
  66.  
  67.      IBM TCP/IP Version 3.1 for OS/2: User's Guide 
  68.  
  69.      IBM TCP/IP Version 3.1 for OS/2: Quick Reference Guide 
  70.  
  71.      IBM Local Area Network Techincal Reference 
  72.  
  73.      This book available on The Developer Connection for LAN Systems CD-ROM: 
  74.  
  75.         -  LAN Technical Reference IEEE 802.2 and NetBIOS APIs 
  76.  
  77.  
  78. ΓòÉΓòÉΓòÉ 2. Sockets General Programming Information ΓòÉΓòÉΓòÉ
  79.  
  80. This section contains technical information for planning, designing, and 
  81. writing application programs that use the sockets application programming 
  82. interface (API) of MPTS in an OS/2 environment. 
  83.  
  84. This section contains information on the following topics: 
  85.  
  86.      MPTS 
  87.      Programming with Sockets 
  88.      Network-Byte Order 
  89.      Multithreading Considerations 
  90.      Typical Socket Session Diagrams 
  91.      Using Socket Calls 
  92.      Porting a Sockets API Application 
  93.      Software Requirements and Toolkit Files 
  94.      Compiling and Linking a Sockets Application 
  95.  
  96.  
  97. ΓòÉΓòÉΓòÉ 2.1. MPTS ΓòÉΓòÉΓòÉ
  98.  
  99. MPTS provides a solution to interconnect applications across networks. MPTS 
  100. provides a 32-bit sockets API for Internet (TCP/IP), local interprocess 
  101. communication (Local IPC), and NetBIOS communication domains.  Network Services 
  102. sockets is based on the Berkeley Software Distribution (BSD) version 4.3 
  103. sockets implementation. 
  104.  
  105. The sockets API allows you to write distributed or client/server applications 
  106. in supported communication domains to allow applications to communicate across 
  107. networks. In addition, the interface allows interprocess communication within 
  108. the same workstation. Applications can have full network access by using the 
  109. sockets API. An existing sockets application can usually be made to run in 
  110. another communications domain by modifying the communications domain section 
  111. and the networking addressing parameters used by the application.  The 
  112. application must then be recompiled and relinked. 
  113.  
  114. Components of Network Services shows a functional relationship between the 
  115. application program and the MPTS Sockets API, supported communication domains, 
  116. and supported network adapters. 
  117.  
  118. Note that the SNA APIs are not part of the sockets programming API and that 
  119. information on the SNA communication domain is not discussed in any portion of 
  120. this book. 
  121.  
  122.  
  123. Components of Network Services
  124.  
  125.  
  126. ΓòÉΓòÉΓòÉ 2.2. Programming with Sockets ΓòÉΓòÉΓòÉ
  127.  
  128. The sockets API allows an application to communicate across networks with other 
  129. applications.  You can, for example, make use of the sockets interface when you 
  130. write a client application that may communicate with a server application 
  131. running on the same or another workstation. 
  132.  
  133. To use sockets, you must know the C programming language. 
  134.  
  135. The MPTS OS/2 sockets API provides a standard interface to all supported 
  136. communication domains: Internet, Local IPC, and NetBIOS. MPTS OS/2 supports 
  137. four socket types: datagram, raw, sequenced packet, and stream.  Each 
  138. communication domain supports certain socket types.  Refer to Socket Types for 
  139. additional information. 
  140.  
  141.  
  142. ΓòÉΓòÉΓòÉ 2.2.1. What is a Socket? ΓòÉΓòÉΓòÉ
  143.  
  144. A socket is an endpoint for communication. From an application program 
  145. perspective, it is a resource allocated by MPTS.  It is represented by an 
  146. integer called a socket descriptor. A pair of sockets, one in each of two 
  147. tasks, is used for interprocess communication (IPC) between them, on a single 
  148. workstation or different workstations. Sockets are full-duplex, which means 
  149. that data can be transmitted and received simultaneously. Each socket is 
  150. created for a particular communication domain and socket type. Communication 
  151. can occur between applications using the same socket type within the same 
  152. communications domain only. 
  153.  
  154. The sockets API is designed to provide applications with access to the network 
  155. while hiding the details of the physical network. You choose a socket type 
  156. (refer to Socket Types) that reflects the communication characteristics that 
  157. you want.  For example, stream sockets offers a reliable method of data 
  158. transmission without message boundaries. 
  159.  
  160.  
  161. ΓòÉΓòÉΓòÉ 2.2.2. Socket Protocol Families and Supported Communication Domains ΓòÉΓòÉΓòÉ
  162.  
  163. Communication domains are specified in MPTS as protocol families. Specifying 
  164. the protocol family identifies the underlying network protocol used during 
  165. communications. All servers in the same protocol family understand and use the 
  166. same scheme of addressing socket endpoints. 
  167.  
  168. The protocol families are defined in the <SYS\SOCKET.H> header file and are 
  169. listed in Communication Domains Supported. 
  170.  
  171. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  172. Γöé Table 1. Communication Domains Supported                   Γöé
  173. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  174. Γöé         Γöé ADDRESS FAMILY   Γöé           Γöé          Γöé
  175. Γöé COMMUNICATION  Γöé #DEFINE IN     Γöé SUPPORTED PROTO-  Γöé SUPPORTED SOCKET Γöé
  176. Γöé DOMAIN     Γöé <SYS\SOCKET.H>   Γöé COLS        Γöé TYPES       Γöé
  177. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  178. Γöé Internet    Γöé AF_INET       Γöé ICMP, IGMP, IP,   Γöé Datagram, Raw,  Γöé
  179. Γöé         Γöé           Γöé TCP, UDP      Γöé Stream      Γöé
  180. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  181. Γöé Local IPC    Γöé AF_OS2, AF_UNIX,  Γöé Local IPC      Γöé Datagram, Stream Γöé
  182. Γöé         Γöé or AF_LOCAL     Γöé           Γöé          Γöé
  183. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  184. Γöé NetBIOS     Γöé AF_NETBIOS or    Γöé NetBIOS       Γöé Datagram,     Γöé
  185. Γöé         Γöé AF_NB        Γöé           Γöé Sequenced Packet Γöé
  186. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  187.  
  188. As Communication Domains Supported indicates, some socket types can be used in 
  189. more than one communications domain. Refer to Socket Types for additional 
  190. information on socket types. 
  191.  
  192. Default Protocols lists the default protocols for each communication 
  193. domain-socket type that is supported. 
  194.  
  195. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  196. Γöé Table 2. Default Protocols                          Γöé
  197. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  198. Γöé COMMUNI-   Γöé          Γöé DEFAULT PROTOCOL   Γöé           Γöé
  199. Γöé CATION    Γöé          Γöé #DEFINE IN      Γöé OTHER PROTOCOLS   Γöé
  200. Γöé DOMAIN    Γöé SOCKET TYPE    Γöé <SYS\SOCKET.H>    Γöé SUPPORTED      Γöé
  201. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  202. Γöé Internet   Γöé Datagram     Γöé UDP (IPPROTO_UDP)   Γöé           Γöé
  203. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  204. Γöé        Γöé Raw        Γöé Raw IP (IPPROTO_RAW) Γöé ICMP        Γöé
  205. Γöé        Γöé          Γöé            Γöé (IPPROTO_ICMP)   Γöé
  206. Γöé        Γöé          Γöé            Γöé IGMP        Γöé
  207. Γöé        Γöé          Γöé            Γöé (IPPROTO_IGMP)   Γöé
  208. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  209. Γöé        Γöé Stream      Γöé TCP (IPPROTO_TCP)   Γöé           Γöé
  210. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  211. Γöé Local IPC   Γöé Datagram     Γöé none (0)       Γöé           Γöé
  212. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  213. Γöé        Γöé Stream      Γöé none (0)       Γöé           Γöé
  214. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  215. Γöé NetBIOS    Γöé Datagram     Γöé NetBIOS (NBPROTO_NB) Γöé           Γöé
  216. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  217. Γöé        Γöé Sequenced Packet Γöé NetBIOS (NBPROTO_NB) Γöé           Γöé
  218. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  219.  
  220.  
  221. ΓòÉΓòÉΓòÉ 2.2.3. Socket Address Families ΓòÉΓòÉΓòÉ
  222.  
  223. An address family is a specific address format that conforms to the rules of 
  224. the communication domain that the address family is used in. The address 
  225. families that are supported by MPTS are defined in the <SYS\SOCKET.H> header 
  226. file and are listed in Socket Address Families. 
  227.  
  228. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  229. Γöé Table 3. Socket Address Families                        Γöé
  230. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  231. Γöé       Γöé                       Γöé ADDRESS FAMILY    Γöé
  232. Γöé ADDRESS   Γöé                       Γöé #DEFINE IN      Γöé
  233. Γöé FAMILY   Γöé DESCRIPTION                 Γöé <SYS\SOCKET.H>    Γöé
  234. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  235. Γöé Internet  Γöé Defines addresses in the Internet Protocol Γöé AF_INET        Γöé
  236. Γöé       Γöé version 4 address format.          Γöé            Γöé
  237. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  238. Γöé Local IPC  Γöé Defines addresses in the Local IPC address Γöé AF_OS2, AF_UNIX, or  Γöé
  239. Γöé       Γöé format.                   Γöé AF_LOCAL       Γöé
  240. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  241. Γöé NetBIOS   Γöé Defines addresses in the NetBIOS address  Γöé AF_NETBIOS or AF_NB  Γöé
  242. Γöé       Γöé format.                   Γöé            Γöé
  243. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  244.  
  245.  
  246. ΓòÉΓòÉΓòÉ 2.2.4. Connection Modes ΓòÉΓòÉΓòÉ
  247.  
  248. A connection mode refers to an established logical channel for the transmission 
  249. of data between two application programs. 
  250.  
  251. The MPTS OS/2 sockets API supports two connection modes: 
  252.  
  253.      Connection-oriented 
  254.      Connectionless 
  255.  
  256.  The connection-oriented mode requires that a logical connection be established 
  257.  between two applications before data transfer or communication can occur. 
  258.  Applications encounter some overhead during the connection establishment phase 
  259.  as the applications negotiate the connection request. This mode is useful for 
  260.  applications that use long datastream transmissions or require reliable 
  261.  transmissions of data. 
  262.  
  263.  The term connected refers to two endpoints that have an established logical 
  264.  connection between them. Stream and sequenced packet socket types use the 
  265.  connection-oriented mode and are always connected. 
  266.  
  267.  The connectionless mode does not require a logical connection to allow 
  268.  communication between applications. Rather, individual messages are 
  269.  transmitted independently from one application to another application. Each 
  270.  message must contain the data and all information required for delivery of the 
  271.  message to its destination. Normally, datagram and raw socket types use the 
  272.  connectionless mode. See "Datagram or raw sockets".. 
  273.  
  274.  
  275. ΓòÉΓòÉΓòÉ 2.3. Socket Types ΓòÉΓòÉΓòÉ
  276.  
  277. Each socket has an associated type, which describes the semantics of 
  278. communication for the socket. The socket type determines the socket 
  279. communication properties such as reliability, ordering, and prevention of 
  280. duplication of messages. The MPTS OS/2 sockets API supports communications 
  281. between applications using the same socket type only. 
  282.  
  283. The socket type is passed as a parameter to the socket() call. Socket Types 
  284. summarizes the attributes and features of each socket type. 
  285.  
  286.  
  287. ΓòÉΓòÉΓòÉ 2.3.1. Stream Sockets ΓòÉΓòÉΓòÉ
  288.  
  289. Stream sockets model duplex byte streams and define a reliable 
  290. connection-oriented service.  Data is sent without errors or duplication and is 
  291. received in the same order as it was sent. Flow control is built in to avoid 
  292. data overruns.  No boundaries are imposed on the data; it is considered to be a 
  293. stream of bytes. 
  294.  
  295. Stream sockets are connected sockets and are either active or passive. Active 
  296. sockets are used by clients who initiate connection requests with connect(). 
  297. Passive sockets are used by servers to accept connection requests with the 
  298. listen() and accept() calls. 
  299.  
  300. Receiving data from any address is supported. 
  301.  
  302. After a connection has been established between stream sockets, any of these 
  303. data transfer calls can be used: 
  304.  
  305.       send() and recv() 
  306.       sendto() and recvfrom() 
  307.       sendmsg() and recvmsg() 
  308.       writev() and readv() 
  309.  
  310.  Usually, a send()-recv() pair is used for sending data on stream sockets. 
  311.  
  312.  
  313. ΓòÉΓòÉΓòÉ 2.3.2. Sequenced Packet Sockets ΓòÉΓòÉΓòÉ
  314.  
  315. Sequenced packet sockets define a reliable connection-oriented service.  Data 
  316. is sent without error or duplication and is received in the same order as it 
  317. was sent.  Flow control is built in to avoid data overruns.  Every sequenced 
  318. packet is sent and received as a complete record. 
  319.  
  320. Receiving data from any address is supported. 
  321.  
  322. After a connection has been established between sequenced packet sockets, any 
  323. of these data transfer calls can be used: 
  324.  
  325.       send() and recv() 
  326.       sendto() and recvfrom() 
  327.       sendmsg() and recvmsg() 
  328.       writev() and readv() 
  329.  
  330.  Usually, a send()-recv() pair is used for sending data on sequenced packet 
  331.  sockets. 
  332.  
  333.  
  334. ΓòÉΓòÉΓòÉ 2.3.3. Datagram Sockets ΓòÉΓòÉΓòÉ
  335.  
  336. Datagram sockets provide connectionless message exchange with no guarantee of 
  337. delivery. Data can be lost or duplicated, and datagrams can arrive out of 
  338. order. Datagrams are sent and received as complete records.  The size of a 
  339. datagram is limited to the size that an underlying protocol supports. 
  340.  
  341. A datagram socket operating in connectionless mode can exchange datagrams using 
  342. the sendto() and recvfrom() calls. 
  343.  
  344. Receiving data from any address is supported. 
  345.  
  346. Datagram sockets are connectionless mode sockets by default.  If an application 
  347. program is using datagram sockets and calls connect() fully specifying the 
  348. destination address, the sockets are considered to be connected. The 
  349. application program can then use the other data transfer calls send() and 
  350. recv() or writev() and readv(). 
  351.  
  352. This method of data transfer stays in effect until connect() is called again 
  353. with a different destination address. Refer to "Datagram or raw sockets". for 
  354. additional information. 
  355.  
  356. Datagram sockets can be used to send broadcast messages in the internet and 
  357. NetBIOS communications domains. For the Internet domain, the broadcast function 
  358. is dependent on the address class and whether subnets are being used.  The 
  359. constant INADDR_BROADCAST, defined in the <SYS\SOCKET.H> file, can be used to 
  360. broadcast to the primary network if the primary network is configured to 
  361. support broadcast.  These comments are defined <NETNB/NB.H> and are NB_UNIQUE, 
  362. NB_GROUP, and NB_BROAD. respectively. For the NetBIOS domain, the address 
  363. format has a type field that specifies whether the address is unique, 
  364. multicast, or broadcast. 
  365.  
  366.  
  367. ΓòÉΓòÉΓòÉ 2.3.4. Raw Sockets ΓòÉΓòÉΓòÉ
  368.  
  369. Raw sockets provide connectionless message exchange with the same data transfer 
  370. semantics as previously described for datagram sockets. You can use raw sockets 
  371. to directly access the protocol specified in the socket() call, such as the 
  372. Internet Protocol (IP), the Internet Control Message Protocol (ICMP), or the 
  373. Internet Group Management Protocol (IGMP). Raw sockets are often used for 
  374. testing new protocol implementations or gaining access to some of the more 
  375. advanced facilities of an existing protocol. 
  376.  
  377. Raw sockets are connectionless mode sockets by default. Raw sockets can be 
  378. connected if connect() is called to specify the destination address. Refer to 
  379. "Datagram or raw sockets". for additional information. 
  380.  
  381.  
  382. ΓòÉΓòÉΓòÉ 2.3.5. Socket Types Summary Tables ΓòÉΓòÉΓòÉ
  383.  
  384. Socket Types summarizes many of the attributes and features of supported socket 
  385. types. 
  386.  
  387. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  388. Γöé Table 4. Socket Types                              Γöé
  389. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  390. Γöé      Γöé           Γöé         Γöé CON-    Γöé         Γöé
  391. Γöé SOCKET   Γöé #DEFINE IN     Γöé         Γöé NECTION  Γöé PRIMARY     Γöé
  392. Γöé TYPE    Γöé <SYS\SOCKET.H>   Γöé DOMAINS     Γöé ORIENTED? Γöé SOCKET CALLS   Γöé
  393. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  394. Γöé Stream   Γöé SOCK_STREAM     Γöé INET, Local   Γöé yes    Γöé send - recv   Γöé
  395. Γöé      Γöé           Γöé IPC, NetBIOS   Γöé      Γöé         Γöé
  396. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  397. Γöé Sequenced Γöé SOCK_SEQPACKET   Γöé NetBIOS     Γöé yes    Γöé send - recv   Γöé
  398. Γöé Packet   Γöé           Γöé         Γöé      Γöé         Γöé
  399. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  400. Γöé Datagram  Γöé SOCK_DGRAM     Γöé INET, Local   Γöé no (*)   Γöé sendto -     Γöé
  401. Γöé      Γöé           Γöé IPC, NetBIOS   Γöé      Γöé recvfrom(*)   Γöé
  402. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  403. Γöé Raw    Γöé SOCK_RAW      Γöé INET       Γöé no (*)   Γöé sendto -     Γöé
  404. Γöé      Γöé           Γöé         Γöé      Γöé recvfrom(*)   Γöé
  405. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  406. Γöé NOTE:  (*) unless the application has called connect() for the socket.  In   Γöé
  407. Γöé this case, the socket is CONNECTED.  Refer to Connection Modes for additional  Γöé
  408. Γöé information.                                  Γöé
  409. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  410.  
  411.  
  412. ΓòÉΓòÉΓòÉ 2.3.6. Guidelines for Using Socket Types ΓòÉΓòÉΓòÉ
  413.  
  414. If you are communicating with an existing application, you must use the same 
  415. socket type and the same communication domain as the existing application. 
  416.  
  417. Raw sockets have a special purpose of interfacing directly to the underlying 
  418. protocol layer. If you are writing a new protocol on top of Internet Protocol 
  419. (IP) or wish to use the Internet Control Message Protocol (ICMP) or the 
  420. Internet Group Management Protocol (IGMP), then you must use a raw sockets. 
  421.  
  422. You should consider the following factors in choosing a socket type for new 
  423. applications: 
  424.  
  425.      Reliability 
  426.  
  427.       Stream sockets provide the most reliable connection. Connectionless mode 
  428.       datagram and raw sockets are unreliable because packets can be discarded, 
  429.       duplicated, or received out of order. This may be acceptable if the 
  430.       application does not require reliability, or if the application 
  431.       implements the reliability on top of the sockets API.  The trade-off is 
  432.       the increased performance available over stream sockets. 
  433.  
  434.      Performance 
  435.  
  436.       The overhead associated with reliability, flow control, packet 
  437.       reassembly, and connection maintenance degrades the performance of stream 
  438.       sockets so that stream sockets do not perform as well as datagram sockets 
  439.       acting in a connectionless mode. 
  440.  
  441.      Amount of data to be transferred 
  442.  
  443.       Datagram sockets impose a limit on the amount of data transferred, 
  444.       depending on the protocol.  As the amount of data in a single transaction 
  445.       increases, it is preferable to use stream sockets. 
  446.  
  447.  
  448. ΓòÉΓòÉΓòÉ 2.3.7. Socket Addresses and Data Structure Format ΓòÉΓòÉΓòÉ
  449.  
  450. A socket can be bound to a unique local name with the bind() call with an 
  451. address so that tasks can connect to it. The socket address format conforms to 
  452. the rules governing network addresses for each communication domain. For 
  453. example, in the Internet communication domain, a host address is a 32-bit value 
  454. that represents one of the ways Internet addresses can be encoded. Each 
  455. communication domain has different rules for valid socket names and 
  456. interpretation of names. 
  457.  
  458. A socket address is defined by the following sockaddr structure, which is found 
  459. in the <SYS\SOCKET.H> header file: 
  460.  
  461. struct sockaddr
  462. {
  463.     u_char sa_family;       /* address family */
  464.     char   sa_data[14];     /* address value */
  465. };
  466.  
  467. The sa_family field contains the address family. 
  468.  
  469. The sa_data field is different for each address family. Each address family 
  470. defines its own structure, which is overlaid on the sockaddr structure. 
  471.  
  472. Socket address structures for the Internet, Local IPC, and NetBIOS 
  473. communication domains (sockaddr_in, sockaddr_un, sockaddr_nb) are described in 
  474. "Addressing within an Internet Domain", Local IPC Address Format, and NetBIOS 
  475. Address Format. 
  476.  
  477.  
  478. ΓòÉΓòÉΓòÉ 2.4. Multithreading Considerations ΓòÉΓòÉΓòÉ
  479.  
  480. The sockets and network utility routines are completely re-entrant. Multiple 
  481. threads of an application can call any socket call. 
  482.  
  483.  
  484. ΓòÉΓòÉΓòÉ 2.5. Typical Socket Session Diagrams ΓòÉΓòÉΓòÉ
  485.  
  486. The following figures show a graphical representation for the general sequence 
  487. of socket calls needed to provide communication between applications for 
  488. supported socket types. This basic sequence is the same for each supported 
  489. communication domain for all supported socket types.  This means that a 
  490. programmer can modify the communications domain selection and the networking 
  491. addressing parameters of an existing sockets program, recompile and relink, and 
  492. the program can be run in another domain.  This also allows programs that use 
  493. sockets in multiple domains to be easily constructed. 
  494.  
  495.  
  496. A Typical Stream or Sequenced Packet Socket Session
  497.  
  498. There is an alternative to the serialized sequence in A Typical Stream or 
  499. Sequenced Packet Socket Session. The server can call accept() to create a new 
  500. thread to handle this new socket. Using the original thread, the server can 
  501. then call accept() again and begin waiting for more requests. 
  502.  
  503.  
  504. A Typical Datagram Socket Session
  505.  
  506.  
  507. ΓòÉΓòÉΓòÉ 2.6. Using Socket Calls ΓòÉΓòÉΓòÉ
  508.  
  509. A detailed description of using the basic socket calls follows. These examples 
  510. show communication between applications in the Internet communication domain 
  511. using stream sockets.  Additional information for other supported domains can 
  512. be found in Sockets over Local IPC and Sockets over NetBIOS. 
  513.  
  514.    1. An application must get a socket descriptor using the socket() call, as 
  515.       in An Application Using the socket() Call. For a more detailed 
  516.       description, see socket(). 
  517.  
  518.  
  519.   An Application Using the socket() Call
  520.  
  521.   int socket(int domain, int type, int protocol); /* extracted from sys\socket.h */
  522.   int s;
  523.   .
  524.   .
  525.   .
  526.   s = socket(AF_INET, SOCK_STREAM, 0);
  527.  
  528.  In this example, the socket() call allocates a socket descriptor s in the 
  529.  Internet communication domain. The communication domain is specified in the 
  530.  domain parameter. The domain is specified with one of the supported protocol 
  531.  families.  This example specifies the protocol family AF_INET. The type 
  532.  parameter is a constant that specifies the type of socket.  For the internet 
  533.  communication domain, this can be SOCK_STREAM, SOCK_DGRAM, or SOCK_RAW. The 
  534.  protocol parameter is a constant that specifies which protocol to use. Passing 
  535.  0 chooses the default protocol for the specified socket type. Refer to Default 
  536.  Protocols for information on default protocols. If successful, socket() 
  537.  returns a non-negative integer socket descriptor. 
  538.  
  539.  After an application has a socket descriptor, it can explicitly bind() a 
  540.  unique name to the socket, as in An Application Using the bind() Call. 
  541.  
  542.  
  543.   An Application Using the bind() Call
  544.  
  545.   int rc;
  546.   int s;
  547.   struct sockaddr_in myname;
  548.   int bind(int s, struct sockaddr *name, int namelen); /* extracted from sys\socket.h */
  549.  
  550.   /* clear the structure */
  551.   memset(&myname, 0, sizeof(myname));
  552.   myname.sin_family = AF_INET;
  553.   myname.sin_addr.s_addr = inet_addr("129.5.24.1"); /* specific interface */
  554.   myname.sin_port = htons(1024);
  555.   .
  556.   .
  557.   .
  558.   rc = bind(s, (struct sockaddr *) &myname, sizeof(myname));
  559.  
  560.  For a server in the Internet domain to be able to use listen() for connections 
  561.  on a stream socket or use recvfrom() on a datagram socket, the server must 
  562.  first use the bind() call to bind the socket to a specific address family and 
  563.  port. This example binds myname to socket s. Note that the sockaddr_in 
  564.  structure should be cleared before calling bind().  For a more detailed 
  565.  description, see bind(). For information on the sockaddr_in structure, see 
  566.  Internet Address Formats. 
  567.  
  568.  The unique name myname specifies that the application uses an internet address 
  569.  family (AF_INET) at internet address 129.5.24.1, and is bound to port 1024. 
  570.  The example in An Application Using the bind() Call shows two useful network 
  571.  utility routines: 
  572.  
  573.      inet_addr()  takes an internet address in dotted-decimal form and returns 
  574.       it in network-byte order. For a more detailed description, see 
  575.       inet_addr(). 
  576.      htons()  takes a port number in host-byte order and returns the port in 
  577.       network-byte order.  For a more detailed description, see htons(). 
  578.  
  579.  A bind() Call Using the getservbyname() Call shows how the bind() call on the 
  580.  server side uses the network utility routine getservbyname() to find a 
  581.  well-known port number for a specified service from the ETC\SERVICES file. For 
  582.  more information on well-known ports, see Ports. 
  583.  
  584.  A bind() Call Using the getservbyname() Call also shows the use of the 
  585.  internet address value INADDR_ANY.  This is the value generally used on a 
  586.  socket bind() call.  It binds the socket to all internet addresses available 
  587.  on the local machine, without requiring the program to know the local internet 
  588.  address. (The code fragment in An Application Using the bind() Call runs 
  589.  successfully only on the machine with internet address 192.5.24.1). If a host 
  590.  has more than one internet address (that is, if it is multihomed host), 
  591.  messages sent to any of the addresses are deliverable to a socket bound to 
  592.  INADDR_ANY. 
  593.  
  594.  
  595.   A bind() Call Using the getservbyname() Call
  596.  
  597.   int rc;
  598.   int s;
  599.   struct sockaddr_in myname;
  600.   int bind(int s, struct sockaddr *name, int namelen); /* extracted from sys\socket.h */
  601.   struct servent *sp;
  602.   .
  603.   .
  604.   .
  605.   sp = getservbyname("login","tcp");  /* get application specific */
  606.                                       /* well-known port          */
  607.  
  608.   .
  609.   .
  610.   .
  611.   /* clear the structure */
  612.   memset(&myname,0,sizeof(myname));
  613.   myname.sin_family = AF_INET;
  614.   myname.sin_addr.s_addr = INADDR_ANY;  /* any interface */
  615.   myname.sin_port = sp->s_port;
  616.   .
  617.   .
  618.   .
  619.   rc = bind(s,(struct sockaddr *)&myname,sizeof(myname));
  620.  
  621.  
  622. ΓòÉΓòÉΓòÉ 2.6.1. Indicating Readiness to Accept Connections ΓòÉΓòÉΓòÉ
  623.  
  624. After binding a name to a socket, a server using stream sockets must indicate 
  625. readiness to accept connections from clients. The server does this with the 
  626. listen() call, as illustrated in the example in An Application Using the 
  627. listen() Call. 
  628.  
  629.  
  630. An Application Using the listen() Call
  631.  
  632. int s;
  633. int backlog;
  634. int rc;
  635. int listen(int s, int backlog);  /* extracted from sys\socket.h */
  636. .
  637. .
  638. .
  639. rc = listen(s, 5);
  640.  
  641. The listen() call is used to indicate the server is ready to accept 
  642. connections. In this example, a maximum of five connection requests can be 
  643. queued for the server. Additional requests are ignored.  For a more detailed 
  644. description, see listen(). 
  645.  
  646.  
  647. ΓòÉΓòÉΓòÉ 2.6.2. Requesting a Connection ΓòÉΓòÉΓòÉ
  648.  
  649. Clients using stream sockets call connect() to request a connection as shown in 
  650. An Application Using the connect() Call. 
  651.  
  652.  
  653. An Application Using the connect() Call
  654.  
  655. int s;
  656. struct sockaddr_in servername;
  657. int rc;
  658. int connect(int s, struct sockaddr *name, int namelen);
  659. /* extracted from sys\socket.h */
  660. .
  661. .
  662. .
  663. memset(&servername, 0,sizeof(servername));
  664. servername.sin_family = AF_INET;
  665. servername.sin_addr.s_addr = inet_addr("129.5.24.1");
  666. servername.sin_port = htons(1024);
  667. .
  668. .
  669. .
  670. rc = connect(s, (struct sockaddr *) &servername, sizeof(servername));
  671.  
  672. The connect() call attempts to connect socket s to the server with the name 
  673. supplied in servername. This could be the server that was used in the previous 
  674. bind() example. With stream sockets the caller optionally blocks until the 
  675. connection request is added to the queue of incoming connections for the 
  676. listening socket. On successful return from connect(), the socket s is 
  677. associated with the connection to the server. Refer to ioctl() for additional 
  678. information about determining blocking and nonblocking behavior. Note that the 
  679. sockaddr_in structure should be cleared before calling connect(). For a more 
  680. detailed description, see connect(). 
  681.  
  682.  
  683. An Application Using the gethostbyname() Call
  684.  
  685. int s;
  686. struct sockaddr_in servername;
  687. char *hostname = "serverhost";
  688. int rc;
  689. int connect(int s, struct sockaddr *name, int namelen);
  690. /* extracted from sys\socket.h */
  691. struct hostent *hp;
  692. .
  693. .
  694. .
  695.  
  696. hp = gethostbyname(hostname);
  697.  
  698. /* clear the structure */
  699. memset(&servername,0,sizeof(servername));
  700. servername.sin_family = AF_INET;
  701. servername.sin_addr.s_addr = *((u_long *)hp->h_addr);
  702. servername.sin_port = htons(1024);
  703. .
  704. .
  705. .
  706. rc = connect(s,(struct sockaddr *)&servername,sizeof(servername));
  707. An Application Using the gethostbyname() Call shows an example of using the 
  708. gethostbyname() network utility routine to find out the internet address of 
  709. serverhost from the name server or the ETC\HOSTS file. 
  710.  
  711.  
  712. ΓòÉΓòÉΓòÉ 2.6.3. Accepting a Connection Request ΓòÉΓòÉΓòÉ
  713.  
  714. Servers using stream sockets accept a connection request with the accept() 
  715. call, as shown in An Application Using the accept() Call. 
  716.  
  717.  
  718. An Application Using the accept() Call
  719.  
  720. int clientsocket;
  721. int s;
  722. struct sockaddr clientaddress;
  723. int addrlen;
  724. int accept(int s, struct sockaddr *addr, int *addrlen);
  725. /* extracted from sys\socket.h */
  726. .
  727. .
  728. .
  729. addrlen = sizeof(clientaddress);
  730. .
  731. .
  732. .
  733. clientsocket = accept(s, &clientaddress, &addrlen);
  734.  
  735. If connection requests are not pending on socket s, the accept() call blocks 
  736. the server unless ioctl() has been called. Refer to ioctl() for additional 
  737. information about determining blocking and nonblocking behavior. When a 
  738. connection request is accepted on socket s, the name of the client and length 
  739. of the client name are returned, along with a new socket descriptor.  The new 
  740. socket descriptor is associated with the client that initiated the connection 
  741. and socket s is again available to accept new connections.  For a more detailed 
  742. description, see accept(). 
  743.  
  744.  
  745. ΓòÉΓòÉΓòÉ 2.6.4. Transferring Data with Connected Sockets ΓòÉΓòÉΓòÉ
  746.  
  747. There are several sockets API calls available to clients and servers for data 
  748. transfer. The readv() and writev(), and send() and recv() calls can be used on 
  749. connected sockets. The sendto() and recvfrom() calls can be used on both 
  750. connected and unconnected sockets. 
  751.  
  752.  
  753. An Application Using the send() and recv() Calls
  754.  
  755. int bytes_sent;
  756. int bytes_received;
  757. char data_sent[256] = "data to be sent on connected socket";
  758. char data_received[256];
  759. int send(int socket, char *buf, int buflen, int flags);
  760. /* extracted from sys\socket.h */
  761. int recv(int socket, char *buf, int buflen, int flags);
  762. /* extracted from sys\socket.h */
  763. int s;
  764. .
  765. .
  766. .
  767. bytes_sent = send(s, data_sent, sizeof(data_sent), 0);
  768. .
  769. .
  770. .
  771. bytes_received = recv(s, data_received, sizeof(data_received), 0);
  772.  
  773. The example in An Application Using the send() and recv() Calls shows an 
  774. application sending data on a connected socket and receiving data in response. 
  775. The flags field can be used to specify additional options to send() or recv(), 
  776. such as sending out-of-band data. For additional information, see send() and 
  777. recv(). 
  778.  
  779.  
  780. ΓòÉΓòÉΓòÉ 2.6.5. Transferring Data with Unconnected Sockets ΓòÉΓòÉΓòÉ
  781.  
  782. If the socket is not connected, additional addressing information must be 
  783. passed using sendto() and can be optionally returned using recvfrom(). An 
  784. example of using the sendto() and recvfrom() calls is shown in An Application 
  785. Using the sendto() and recvfrom() Calls. 
  786.  
  787.  
  788. An Application Using the sendto() and recvfrom() Calls
  789.  
  790. int bytes_sent;
  791. int bytes_received;
  792. char data_sent[256] = "data to be sent using sendto()";
  793. char data_received[256];
  794. struct sockaddr_in to;
  795. struct sockaddr from;
  796. int addrlen;
  797. int sendto(int socket, char *buf, int buflen, int flags,
  798.            struct sockaddr *addr, int addrlen);      /* extracted from sys\socket.h */
  799. int recvfrom(int socket, char *buf, int buflen, int flags,
  800.            struct sockaddr *addr, int *addrlen);     /* extracted from sys\socket.h */
  801. int s;
  802. .
  803. .
  804. .
  805. memset(&to, 0, sizeof(to));
  806. to.sin_family = AF_INET;
  807. to.sin_addr.s_addr   = inet_addr("129.5.24.1");
  808. to.sin_port   = htons(1024);
  809. .
  810. .
  811. .
  812. bytes_sent = sendto(s, data_sent, sizeof(data_sent), 0,
  813. (struct sockaddr *) &to, sizeof(to));
  814. .
  815. .
  816. .
  817. addrlen = sizeof(from); /* must be initialized */
  818. bytes_received = recvfrom(s, data_received, sizeof(data_received), 0, &from, &addrlen);
  819.  
  820. The sendto() and recvfrom() calls take additional parameters that allow the 
  821. caller to specify the recipient of the data or to be notified of the sender of 
  822. the data. See recvfrom(), and sendto(), for more information about these 
  823. additional parameters. 
  824.  
  825.  
  826. ΓòÉΓòÉΓòÉ 2.6.6. Transferring Data with Scatter/Gather Features ΓòÉΓòÉΓòÉ
  827.  
  828. The writev() and readv() calls, shown in An Application Using the writev() and 
  829. readv() Calls, provide the additional features of scatter/gather read/write of 
  830. data. Scattered data can be located in multiple data buffers. The writev() call 
  831. gathers the scattered data and sends it. The readv() call receives data and 
  832. scatters it into multiple buffers. 
  833.  
  834.  
  835. An Application Using the writev() and readv() Calls
  836.  
  837. int s, iovcnt, bytes_sent, bytes_read;
  838. struct iovec iov[3];
  839.  
  840. char header_out[]  = "This is the header";
  841. char data_out[]    = "This is the data";
  842. char trailer_out[] = "This is the trailer";
  843. char header_in[18];
  844. char data_in[16];
  845. char trailer_in[19];
  846. .
  847. .
  848. .
  849. /* Put data in buffers */
  850. iovcnt = 3;
  851. iov[0].iov_base = header_out;
  852. iov[0].iov_len = sizeof(header_out);
  853. iov[1].iov_base = data_out;
  854. iov[1].iov_len = sizeof(data_out);
  855. iov[2].iov_base = trailer_out;
  856. iov[2].iov_len = sizeof(trailer_out);
  857.  
  858. /* Send the message in buffers to the server */
  859. bytes_sent = writev(s, iov, iovcnt);
  860. .
  861. .
  862. .
  863. iov[0].iov_base = header_in;
  864. iov[0].iov_len = sizeof(header_in);
  865. iov[1].iov_base = data_in;
  866. iov[1].iov_len = sizeof(data_in);
  867. iov[2].iov_base = trailer_in;
  868. iov[2].iov_len = sizeof(trailer_in);
  869.  
  870. /* Read the message in buffers */
  871. bytes_read = readv(s, iov, iovcnt);
  872.  
  873.  
  874. ΓòÉΓòÉΓòÉ 2.6.7. Transferring Data with Multiple Sockets ΓòÉΓòÉΓòÉ
  875.  
  876. Applications can handle multiple sockets. In such situations, you can use the 
  877. select() call to determine the sockets that have data to be read, those that 
  878. are ready for data to be written, and the sockets that have pending exception 
  879. conditions. If the timeout parameter is positive, select() waits up to this 
  880. amount of time for at least one socket to become ready on the indicated 
  881. conditions. This is useful for applications servicing multiple connections that 
  882. cannot afford to block and are waiting for data on one connection. 
  883.  
  884.  
  885. An Application Uses the BSD Version select() Call
  886.  
  887. #define BSD_SELECT
  888.  
  889. fd_set readsocks;
  890. fd_set writesocks;
  891. fd_set exceptsocks;
  892. struct timeval timeout;
  893. int number_of_sockets;
  894. int number_found;
  895. .
  896. .
  897. .
  898. /* set bits in read write except bit masks.  To set mask for a descriptor s use
  899. *   readsocks |= fd_set(s);
  900. *
  901. * set number of sockets to be checked
  902. * number_of_sockets = x;
  903. */
  904. .
  905. .
  906. .
  907. number_found = select(number_of_sockets,
  908.                       &readsocks, &writesocks, &exceptsocks, &timeout);
  909.  
  910. In this example, the application indicates the sockets to be checked for 
  911. readability or readiness for writing. 
  912.  
  913.  
  914. ΓòÉΓòÉΓòÉ 2.6.8. Using Asynchronous Socket Operations ΓòÉΓòÉΓòÉ
  915.  
  916. In addition to select(), applications can use the ioctl() call to help perform 
  917. asynchronous (nonblocking) socket operations.  An example of the use of the 
  918. ioctl() call is shown in An Application Using the ioctl() Call. 
  919.  
  920.  
  921. An Application Using the ioctl() Call
  922.  
  923. int s;
  924. int bytes_received;
  925. int dontblock;
  926. char buf[256];
  927. int rc;
  928. int ioctl(int s, int command, char *command_data, int datasize);
  929.                                   /* extracted from sys\socket.h */
  930. .
  931. .
  932. .
  933. dontblock = 1;
  934. .
  935. .
  936. .
  937. rc = ioctl(s, FIONBIO, (char *) &dontblock, sizeof(dontblock));
  938. .
  939. .
  940. .
  941. bytes_received = recv(s, buf, sizeof(buf), 0);
  942. if (bytes_received == -1)
  943. {
  944.   if (sock_errno() == SOCEWOULDBLOCK)
  945.              /* data is not present */
  946.   else
  947.              /* error occurred */
  948. }
  949. else
  950.    /* bytes_ received indicates amount of data received in buf */
  951.  
  952. This example causes the socket s to be placed in nonblocking mode.  When this 
  953. socket is passed as a parameter to calls that would block, such as recv() when 
  954. data is not present, it causes the call to return with an error code, and sets 
  955. the error value to SOCEWOULDBLOCK.  Setting the mode of the socket to be 
  956. nonblocking allows an application to continue processing without becoming 
  957. blocked. For a more detailed description, see ioctl(). 
  958.  
  959.  
  960. ΓòÉΓòÉΓòÉ 2.6.9. Deallocating a Socket Descriptor ΓòÉΓòÉΓòÉ
  961.  
  962. The socket descriptor s is deallocated with the soclose() call. For a more 
  963. detailed description, see soclose(). An example of the soclose() call is shown 
  964. in An Application Using the soclose() Call. 
  965.  
  966.  
  967. An Application Using the soclose() Call
  968.  
  969. int soclose(int s);   /* extracted from sys\socket.h */
  970. .
  971. .
  972. .
  973. /* close the socket */
  974. soclose(s);
  975. .
  976. .
  977. .
  978.  
  979.  
  980. ΓòÉΓòÉΓòÉ 2.7. Porting a Sockets API Application ΓòÉΓòÉΓòÉ
  981.  
  982. MPTS OS/2 sockets is based on the Berkeley Software Distribution Version 4.3 
  983. sockets implementation. 
  984.  
  985.      Sockets are not OS/2 Warp files or devices. Socket descriptors have no 
  986.       relationship to OS/2 Warp file handles. Therefore, file-related calls 
  987.       such as read(), write(), and close() do not work for sockets. Use the 
  988.       recv(), send(), and soclose() functions instead. 
  989.  
  990.      To access MPTS return values, add the following include statement: 
  991.  
  992.             #include <nerrno.h>
  993.  
  994.       Error codes set by the MPTS OS/2 sockets API are not made available using 
  995.       the global errno variable.  Instead, error codes are accessed by using 
  996.       the sock_errno() API described in sock_errno().  Use psock_errno(), 
  997.       instead of perror(), to write a short error message on the standard error 
  998.       device describing the last error encountered during a call to a socket 
  999.       library function. This is intended to obtain per-thread error codes in a 
  1000.       multithreaded application environment and to avoid problems with 
  1001.       conflicting errno constants defined by some compilers. 
  1002.  
  1003.       For compatibility with Berkeley Software Distribution (BSD), an 
  1004.       application can choose to define: 
  1005.  
  1006.             #define errno sock_errno()
  1007.             #define perror psock_errno
  1008.  
  1009.       Place these definitions after # include <SYS\SOCKET.H>. 
  1010.  
  1011.       If a source file includes code that checks errno for both OS/2 Warp 
  1012.       socket and OS/2 Warp nonsocket functions, this mechanism cannot be used. 
  1013.  
  1014.       BSD-style error checking is as follows: 
  1015.  
  1016.             rt = recv(s, buf, sizeof(buf), 0);
  1017.             if (rt == -1 && errno == SOCEWOULDBLOCK)
  1018.                {...}
  1019.  
  1020.             if (recv(s, buf, sizeof(buf), 0) < 0)
  1021.             {
  1022.                 perror("Recv()");
  1023.                 exit(1);
  1024.             }
  1025.  
  1026.       The preferred OS/2 Warp-style error checking is as follows: 
  1027.  
  1028.             rt = recv(s, buf, sizeof(buf), 0);
  1029.             if (rt == -1 && sock_errno() == SOCEWOULDBLOCK)
  1030.                {...}
  1031.  
  1032.             if (recv(s, buf, sizeof(buf), 0) < 0)
  1033.             {
  1034.                 psock_errno("Recv()");
  1035.                 exit(1);
  1036.             }
  1037.  
  1038.       Error constants consistent with BSD sockets are provided for 
  1039.       compatibility purposes; your application can use the error constant 
  1040.       EWOULDBLOCK instead of SOCEWOULDBLOCK. Refer to Socket Error Return Code 
  1041.       Constants, or the <NERRNO.H> file for definitions of error constants. 
  1042.  
  1043.      Unlike the BSD select() call, you cannot use the OS/2 select() call to 
  1044.       wait for activity on devices other than sockets. See select() for more 
  1045.       information. 
  1046.  
  1047.      The ioctl() interface differs slightly from the current BSD ioctl() 
  1048.       implementation. For example, IBM has added a lendata parameter, which the 
  1049.       current BSD ioctl() implementation does not require. Other functions of 
  1050.       the IBM ioctl() call also differ from the current BSD ioctl() 
  1051.       implementation in some cases. In addition, the getsockopt() and 
  1052.       setsockopt() provides support for additional protocol-specific options. 
  1053.       For more information, see: 
  1054.  
  1055.            ioctl() 
  1056.            getsockopt() 
  1057.            setsockopt() 
  1058.  
  1059.  Mapping NetBIOS Control Block (NCB) Calls to Socket Calls 
  1060.  
  1061.  The following lists the NCB calls and the appropriate socket calls to map to. 
  1062.  
  1063.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  1064.   Γöé Table 5. NCB Calls to Socket Calls Mapping                                      Γöé
  1065.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1066.   Γöé NCB CALL            Γöé SOCKET CALL(S)                                    Γöé
  1067.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1068.   Γöé NCB.ADD.GROUP.NAME       Γöé bind()                                        Γöé
  1069.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1070.   Γöé NCB.ADD.NAME          Γöé bind()                                        Γöé
  1071.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1072.   Γöé NCB.CALL            Γöé connect()                                      Γöé
  1073.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1074.   Γöé NCB.CANCEL           Γöé N/A                                         Γöé
  1075.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1076.   Γöé NCB.CHAIN.SEND         Γöé sendmsg(), writev()                                 Γöé
  1077.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1078.   Γöé NCB.CHAIN.SEND.NO.ACK      Γöé sendmsg(), writev()                                 Γöé
  1079.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1080.   Γöé NCB.DELETE.NAME         Γöé soclose()                                      Γöé
  1081.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1082.   Γöé NCB.FIND.NAME          Γöé N/A                                         Γöé
  1083.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1084.   Γöé NCB.GATHER.SEND         Γöé sendmsg(), writev()                                 Γöé
  1085.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1086.   Γöé NCB.HANG.UP           Γöé soclose()                                      Γöé
  1087.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1088.   Γöé NCB.LAN.STATUS.ALERT      Γöé N/A                                         Γöé
  1089.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1090.   Γöé NCB.LISTEN           Γöé listen() + accept() *                                Γöé
  1091.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1092.   Γöé *:  After you call listen() and accept(), you can call accept() multiple times without calling listen() again.    Γöé
  1093.   Γöé This is functionally equivalent to multiple calls of NCB.LISTEN.  For example, if you call NCB.LISTEN three times,  Γöé
  1094.   Γöé the mapping would be:                                                 Γöé
  1095.   Γöé                                                            Γöé
  1096.   Γöé    NCB.LISTEN #1 ΓöÇΓöÇΓöÇ> listen() + accept()                                      Γöé
  1097.   Γöé    NCB.LISTEN #2 ΓöÇΓöÇΓöÇ> accept()                                           Γöé
  1098.   Γöé    NCB.LISTEN #3 ΓöÇΓöÇΓöÇ> accept()                                           Γöé
  1099.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1100.   Γöé NCB.RECEIVE           Γöé readv(), recv(), recvfrom(), recvmsg() **                      Γöé
  1101.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1102.   Γöé **:  With NCB.RECEIVE calls, you must issue a receive call before the send call is issued.  With the socket read   Γöé
  1103.   Γöé and receive calls, you can issue the send and receive calls in any order.                       Γöé
  1104.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1105.   Γöé NCB.RECEIVE.ANY         Γöé readv(), recv(), recvfrom(), recvmsg() **                      Γöé
  1106.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1107.   Γöé NCB.RECEIVE.BROADCAST.DATAGRAM Γöé recvfrom(), recvmsg() **                               Γöé
  1108.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1109.   Γöé NCB.RECEIVE.DATAGRAM      Γöé recvfrom(), recvmsg() **                               Γöé
  1110.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1111.   Γöé NCB.RESET            Γöé N/A                                         Γöé
  1112.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1113.   Γöé NCB.SCATTER.RECV.ANY      Γöé readv(), recvmsg()                                  Γöé
  1114.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1115.   Γöé NCB.SEND            Γöé send(), sendmsg(), sendto(), writev()                        Γöé
  1116.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1117.   Γöé NCB.SEND.BROADCAST.DATAGRAM   Γöé sendmsg(), sendto()                                 Γöé
  1118.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1119.   Γöé NCB.SEND.DATAGRAM        Γöé connect() + send(), sendmsg(), sendto()                       Γöé
  1120.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1121.   Γöé NCB.SEND.NOACK         Γöé send(), sendmsg(), sendto(), writev()                        Γöé
  1122.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1123.   Γöé NCB.SESSION.STATUS       Γöé N/A                                         Γöé
  1124.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1125.   Γöé NCB.STATUS           Γöé N/A                                         Γöé
  1126.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1127.   Γöé NCB.UNLINK           Γöé N/A                                         Γöé
  1128.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  1129.  
  1130.  In general, select() is used when a no-wait NCB call is simulated. For 
  1131.  example, for a no-wait NCB.CALL, a connect() would be issued and then a 
  1132.  select() to determine when the connection is made successfully. 
  1133.  
  1134.  
  1135. ΓòÉΓòÉΓòÉ 2.8. Software Requirements and Toolkit Files ΓòÉΓòÉΓòÉ
  1136.  
  1137. This section describes the software requirements for running the MPTS code and 
  1138. also lists the socket header and library files. 
  1139.  
  1140.  
  1141. ΓòÉΓòÉΓòÉ 2.8.1. Software Requirements ΓòÉΓòÉΓòÉ
  1142.  
  1143. You must have the following software installed on your system: 
  1144.  
  1145.      OS/2 Warp 
  1146.      OS/2 Warp MPTS 
  1147.      IBM C Set/2 
  1148.  
  1149.  If installing MPTS on top of a previous version of MPTS OR NTS/2, be aware 
  1150.  that the Toolkit files for developers are no longer installed. To unpack the 
  1151.  Socket files into the desired directory, insert MPTS Diskette 5 into drive A: 
  1152.  on the code server and type the following command: 
  1153.  
  1154.        PKUNZIP2 -d A:\TOOLKIT\MPTNTK.ZIP <e:\path>
  1155.  
  1156.  The following example places the MPTS developer toolkit files in drive C: 
  1157.  
  1158.        PKUNZIP2 -d A:\TOOLKIT\MPTNTK.ZIP C:\
  1159.  
  1160.  Note:  If MPTS is not installed on the workstation where you are unpacking the 
  1161.  MPTS Toolkit, you must copy the PKUNZIP2.EXE program from the root directory 
  1162.  of MPTS Diskette 1 into a directory that is in the current path. 
  1163.  
  1164.  
  1165. ΓòÉΓòÉΓòÉ 2.8.2. Header and Library Files ΓòÉΓòÉΓòÉ
  1166.  
  1167. This section lists the header and library files that are installed from the 
  1168. Socket Toolkit to your workstation. 
  1169.  
  1170.  
  1171. ΓòÉΓòÉΓòÉ 2.8.2.1. Header Files ΓòÉΓòÉΓòÉ
  1172.  
  1173. The following are the socket application header files . 
  1174.  
  1175. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  1176. Γöé Table 6. Header Files                           Γöé
  1177. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1178. Γöé HEADER FILE      Γöé DESCRIPTION                     Γöé
  1179. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1180. Γöé ARPA\NAMESER.H    Γöé IP name server definition              Γöé
  1181. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1182. Γöé NET\IF.H       Γöé TCP/IP network interface definition         Γöé
  1183. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1184. Γöé NET\IF_ARP.H     Γöé TCP/IP ARP protocol definition           Γöé
  1185. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1186. Γöé NET\ROUTE.H      Γöé TCP/IP routing table definition           Γöé
  1187. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1188. Γöé NETDB.H        Γöé TCP/IP network utility definitions         Γöé
  1189. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1190. Γöé NETNB\NB.H      Γöé NetBIOS address structure definition        Γöé
  1191. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1192. Γöé NERRNO.H       Γöé MPTS error code definitions             Γöé
  1193. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1194. Γöé NETINET\IN.H     Γöé IP constants and structures             Γöé
  1195. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1196. Γöé NETINET\IF_ETHER.H  Γöé Ethernet structures                 Γöé
  1197. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1198. Γöé NETINET\IN_SYSTM.H  Γöé Internetwork definitions for kernel         Γöé
  1199. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1200. Γöé NETINET\IP.H     Γöé IP definitions                   Γöé
  1201. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1202. Γöé NETINET\IP_ICMP.H   Γöé ICMP definitions                  Γöé
  1203. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1204. Γöé CRYPT.H        Γöé Crypt structures                  Γöé
  1205. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1206. Γöé FTPAPI.H       Γöé FTP structures                   Γöé
  1207. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1208. Γöé GRP.H         Γöé Group definitions                  Γöé
  1209. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1210. Γöé NETLIB.H       Γöé NETLIB definitions                 Γöé
  1211. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1212. Γöé PWD.H         Γöé Password structures                 Γöé
  1213. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1214. Γöé SYSLOG.H       Γöé System log definitions               Γöé
  1215. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1216. Γöé RESOLV.H       Γöé IP name resolution definitions           Γöé
  1217. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1218. Γöé SYS\IOCTL.H      Γöé Input/output control definitions          Γöé
  1219. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1220. Γöé SYS\SELECT.H     Γöé BSD_SELECT definitions               Γöé
  1221. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1222. Γöé SYS\SOCKET.H     Γöé Socket definitions and structures          Γöé
  1223. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1224. Γöé SYS\TIME.H      Γöé Time_val structures                 Γöé
  1225. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1226. Γöé SYS\UN.H       Γöé Local IPC structures                Γöé
  1227. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1228. Γöé TYPES.H        Γöé Data type definitions                Γöé
  1229. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1230. Γöé UTILS.H        Γöé TCP/IP utility routine definitions         Γöé
  1231. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  1232.  
  1233.  
  1234. ΓòÉΓòÉΓòÉ 2.8.2.2. Library Files ΓòÉΓòÉΓòÉ
  1235.  
  1236. Library Files and DLL Files and Their Application list library files an 
  1237. application must link to. 
  1238.  
  1239. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  1240. Γöé Table 7. Library Files                        Γöé
  1241. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1242. Γöé LIBRARY FILE  Γöé DESCRIPTION                     Γöé
  1243. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1244. Γöé SO32DLL.LIB   Γöé Linkable library containing the 32-bit protocol-  Γöé
  1245. Γöé         Γöé independent socket entry point descriptions     Γöé
  1246. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1247. Γöé TCP32DLL.LIB  Γöé Linkable library containing the 32-bit       Γöé
  1248. Γöé         Γöé TCP/IP-specific network utility routine entry    Γöé
  1249. Γöé         Γöé point descriptions                 Γöé
  1250. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1251. Γöé TCPIPDLL.LIB  Γöé Linkable library containing 16-bit TCP/IP-specific Γöé
  1252. Γöé         Γöé network routine entry point descriptions      Γöé
  1253. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  1254.  
  1255. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  1256. Γöé Table 8. DLL Files and Their Application               Γöé
  1257. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1258. Γöé DLL FILE    Γöé APPLICATION                     Γöé
  1259. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1260. Γöé SO32DLL.DLL   Γöé Dynamically linked library containing the 32-bit  Γöé
  1261. Γöé         Γöé protocol-independent socket calls          Γöé
  1262. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1263. Γöé TCP32DLL.DLL  Γöé Dynamically linked library containing the 32-bit  Γöé
  1264. Γöé         Γöé TCP/IP specific network utility routines      Γöé
  1265. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1266. Γöé TCCPIPDLL.DLL  Γöé dynamically linked library containing the 16-bit  Γöé
  1267. Γöé         Γöé TCP/IP-specfic newtork utility routines       Γöé
  1268. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  1269.  
  1270. Note:  All DLL files must reside in a directory listed in the LIBPATH system 
  1271. environment variable for the program to run. 
  1272.  
  1273.  
  1274. ΓòÉΓòÉΓòÉ 2.9. Compiling and Linking a Sockets Application ΓòÉΓòÉΓòÉ
  1275.  
  1276. The following steps describe the compiling and linking procedures for a sockets 
  1277. application using the C++ compiler. 
  1278.  
  1279. Set your environment variables to find the following: 
  1280.  
  1281.      Executable programs 
  1282.      Link libraries 
  1283.      Header files 
  1284.  You can set the environment variables interactively, or you can include them 
  1285.  in your CONFIG.SYS file. The following is an example of the entries you may 
  1286.  have in your CONFIG.SYS file. 
  1287.  
  1288.      SET PATH=C:\IBMC\BIN;%PATH%
  1289.      SET DPATH=C:\IBMC\LOCALE;C:\IBMC\HELP;%DPATH%
  1290.      SET LIB=C:\IBMC\LIB;C:\MPTN\LIB;%LIB%
  1291.      SET INCLUDE=C:\IBMC\INCLUDE;C:\MPTN\INCLUDE;%INCLUDE%
  1292.      SET HELP=C:\IBMC\HELP;%HELP%
  1293.      SET BOOKSHELF=C:\IBMC\HELP;%BOOKSHELF%
  1294.      SET TZ=EST5EDT,0,0,0,0,0,0,0,0,0
  1295.  
  1296.  To compile your program, enter the following command: 
  1297.  
  1298.        icc /C+ /DMPTN /DSO32 /DOS2 myprog
  1299.  
  1300.      For a dynamically linked, single-threaded program: 
  1301.  
  1302.        LINK386 myprog.obj,,DDE4SBS.LIB DDE4SBM.LIB SO32DLL.LIB TCP32DLL.LIB
  1303.        OS2386.LIB
  1304.  
  1305.      For a dynamically linked, multithreaded program: 
  1306.  
  1307.        LINK386 myprog.obj,,DDE4MBS.LIB DDE4MBM.LIB SO32DLL.LIB TCP32DLL.LIB
  1308.        OS2386.LIB
  1309.  
  1310.  Notes: 
  1311.  
  1312.    1. When running an application that is built using DLL, the LIBPATH 
  1313.       environment variable in your CONFIG.SYS file must include the MPTS\DLL 
  1314.       directory. 
  1315.  
  1316.    2. For more information about the compile and link option, multithreaded 
  1317.       libraries, and dynamic link libraries, see the IBM C Set/2 User's Guide. 
  1318.  
  1319.    3. You must include the MPTS library header files to ensure that proper 
  1320.       function declaration and parameter types are used. 
  1321.  
  1322.  
  1323. ΓòÉΓòÉΓòÉ 3. Sockets in the Internet Domain ΓòÉΓòÉΓòÉ
  1324.  
  1325. This section includes: 
  1326.  
  1327.      Protocols Used in the Internet Domain 
  1328.      Getting Started with Sockets in the Internet Domain 
  1329.      Network-Byte Order 
  1330.      Internet Address Formats 
  1331.      TCP/IP-specific Network Utility Routines 
  1332.  
  1333.  
  1334. ΓòÉΓòÉΓòÉ 3.1. Protocols Used in the Internet Domain ΓòÉΓòÉΓòÉ
  1335.  
  1336. This section describes the network protocols in TCP/IP. Only the internet 
  1337. domain is supported by the TCP/IP protocol suite. Networking protocols such as 
  1338. TCP/IP are layered as shown in The Internet Layered Architecture. For more 
  1339. information on the internet domain and the TCP/IP protocol suite, refer to 
  1340. TCP/IP Illustrated, Volume 1: The Protocols. 
  1341.  
  1342.  
  1343. The Internet Layered Architecture
  1344.  
  1345.  
  1346. ΓòÉΓòÉΓòÉ 3.1.1. Transmission Control Protocol ΓòÉΓòÉΓòÉ
  1347.  
  1348. Transmission Control Protocol (TCP) is a transport protocol that provides a 
  1349. reliable mechanism for delivering packets between hosts on an internet network. 
  1350. TCP takes a stream of data, breaks it into datagrams, sends each one 
  1351. individually using IP, and reassembles the datagrams at the destination node. 
  1352. If any datagrams are lost or damaged during transmission, TCP detects this and 
  1353. resends the missing datagrams. The received data stream is a reliable copy of 
  1354. the transmitted data stream. 
  1355.  
  1356. You can use TCP sockets for both passive (server) and active (client) 
  1357. applications. Some calls are necessary for both types; others are 
  1358. role-specific. TCP is the default protocol for stream sockets in the internet 
  1359. domain. 
  1360.  
  1361. TCP is a connection-oriented protocol.  It is used to communicate between pairs 
  1362. of applications. After a connection is made, it exists until the socket is 
  1363. closed. During the connection, data is either delivered or an error code is 
  1364. returned by Network Services. 
  1365.  
  1366.  
  1367. ΓòÉΓòÉΓòÉ 3.1.2. User Datagram Protocol ΓòÉΓòÉΓòÉ
  1368.  
  1369. User Datagram Protocol (UDP) is a transport-layer datagram protocol that sends 
  1370. and receives whole packets across the network. UDP does not offer a guarantee 
  1371. of datagram delivery or duplication protection.  UDP provides checksums for 
  1372. both the header and data portions of a datagram. However, applications that 
  1373. require reliable delivery of streams of data should use TCP. UDP is the default 
  1374. protocol for datagram sockets in the internet domain. 
  1375.  
  1376. Unlike applications using TCP, UDP applications are usually connectionless.  A 
  1377. UDP socket application can become connected by calling the connect() API. An 
  1378. unconnected socket can be used to communicate with many hosts; but a connected 
  1379. socket, because it has a dedicated destination, can send data to, and receive 
  1380. data from, only one host at a time. 
  1381.  
  1382. UDP is considered an unreliable protocol because it sends its data over the 
  1383. network without verification. Consequently, after a packet has been accepted by 
  1384. the UDP interface, the arrival of the packet and the arrival order of the 
  1385. packet at the destination cannot be guaranteed. 
  1386.  
  1387.  
  1388. ΓòÉΓòÉΓòÉ 3.1.3. Internet Protocol ΓòÉΓòÉΓòÉ
  1389.  
  1390. The Internet Protocol (IP) network layer provides the interface from the 
  1391. transport layer (host-to-host) protocols to the link-level protocols. IP is the 
  1392. basic transport mechanism for routing IP packets to the next gateway, router, 
  1393. or destination host. 
  1394.  
  1395. IP transmits packets of data from sources to destinations. Sources and 
  1396. destinations are hosts identified by 32-bit IP addresses, which are assigned 
  1397. independent of the underlying physical network. Outgoing packets automatically 
  1398. have an IP header prefixed to them, and incoming packets have their IP header 
  1399. removed before being sent to the higher-level protocols. This protocol provides 
  1400. for the unique addressing of hosts in an internet network. 
  1401.  
  1402. IP does not ensure a reliable communication, because it does not require 
  1403. acknowledgments from the sending host, the receiving host, or intermediate 
  1404. hosts. IP does not provide error control for data; it provides only a header 
  1405. checksum. IP treats each packet as an independent entity unrelated to any other 
  1406. packet. IP does not perform retransmissions or flow control. A higher-level 
  1407. protocol, TCP/IP for example, that uses IP must implement its own reliability 
  1408. procedures. 
  1409.  
  1410. Applications do not typically access IP directly, but rather use TCP or UDP 
  1411. which, in turn, use IP. Raw sockets can use IP. 
  1412.  
  1413.  
  1414. ΓòÉΓòÉΓòÉ 3.1.4. Internet Control Message Protocol ΓòÉΓòÉΓòÉ
  1415.  
  1416. Internet Control Message Protocol (ICMP) is used to pass control information 
  1417. between hosts. For example, the information can be sent when a: 
  1418.  
  1419.      Host checks to see if another host is available (PING). 
  1420.      Packet cannot reach its destination. 
  1421.      Gateway or router can direct a host to send traffic on a shorter route. 
  1422.      Gateway or router does not have the buffering capacity to forward a 
  1423.       packet. 
  1424.  
  1425.  ICMP provides feedback about problems in the communication environment; it 
  1426.  does not make IP reliable. The use of ICMP does not guarantee that an IP 
  1427.  packet is delivered reliably or that an ICMP message is returned to the source 
  1428.  host when an IP packet is not delivered or is incorrectly delivered. 
  1429.  
  1430.  Raw sockets can use ICMP and similar to IP, ICMP is not typically used by 
  1431.  application programs directly. 
  1432.  
  1433.  
  1434. ΓòÉΓòÉΓòÉ 3.1.5. Internet Group Management Protocol ΓòÉΓòÉΓòÉ
  1435.  
  1436. Internet Group Management Protocol (IGMP) is used to communicate group 
  1437. membership information to hosts and routers on the network.  When a host joins 
  1438. a multicast group, it sends an IGMP message announcing the host membership to 
  1439. the all-hosts multicast address (224.0.0.1). Because hosts do not send out 
  1440. messages when they leave a group, the gateways must periodically poll the hosts 
  1441. on the local network.  The hosts send a membership report in response to the 
  1442. poll. 
  1443.  
  1444.  
  1445. ΓòÉΓòÉΓòÉ 3.1.6. Address Resolution Protocol ΓòÉΓòÉΓòÉ
  1446.  
  1447. Address Resolution Protocol (ARP) maps IP addresses to hardware addresses. 
  1448. TCP/IP uses ARP to collect and distribute the information for mapping tables. 
  1449.  
  1450. ARP is not directly available to users or applications. When an application 
  1451. sends an internet packet, IP requests the appropriate address mapping. If the 
  1452. mapping is not in the mapping table, an ARP broadcast packet is sent to all the 
  1453. hosts on the local network requesting the physical hardware address for the 
  1454. host. 
  1455.  
  1456.  
  1457. ΓòÉΓòÉΓòÉ 3.2. Getting Started with Sockets in the Internet Domain ΓòÉΓòÉΓòÉ
  1458.  
  1459. This section provides some basic information for getting started with sockets 
  1460. in the internet domain: 
  1461.  
  1462.      Use the socket() call to create a socket in the internet domain 
  1463.       specifying PF_INET for the domain parameter. 
  1464.  
  1465.      Use AF_INET for the address family. 
  1466.  
  1467.      The following socket types are supported for the internet domain: 
  1468.  
  1469.         -  Datagram (SOCK_DGRAM) 
  1470.         -  Raw (SOCK_RAW) 
  1471.         -  Stream (SOCK_STREAM) The socket type is passed as a parameter to the 
  1472.       socket() call. For additional information, refer to Socket Types and 
  1473.       general socket programming concepts in Programming with Sockets. 
  1474.  
  1475.      Datagram sockets use the UDP protocol, stream sockets use the TCP 
  1476.       protocol, and raw sockets can use the raw, ICMP, or IGMP protocols. 
  1477.  
  1478.      Use the network utility routines to get addresses with a given name 
  1479.       (refer to TCP/IP-specific Network Utility Routines for additional 
  1480.       information.) 
  1481.  
  1482.  
  1483. ΓòÉΓòÉΓòÉ 3.3. Network-Byte Order ΓòÉΓòÉΓòÉ
  1484.  
  1485. Ports and addresses are specified to socket API calls by using the network-byte 
  1486. ordering convention. Network-byte order is also known as big endian byte 
  1487. ordering which has the high-order byte at the starting address. By contrast, 
  1488. little endian has the low-order byte at the starting address. Using 
  1489. network-byte ordering for data exchanged between hosts allows hosts using 
  1490. different underlying byte ordering conventions to exchange address information. 
  1491. There is a set of network utility API calls for translating addresses from 
  1492. host-byte to network-byte order and from network-byte to host-byte order. For 
  1493. more information about network-byte order and address translation, see: 
  1494.  
  1495.      bind() 
  1496.      htonl() 
  1497.      htons() 
  1498.      ntohl() 
  1499.      ntohs() 
  1500.  
  1501.  Note:  The socket interface does not handle application data byte ordering 
  1502.         differences. Application writers must handle data buffer byte order 
  1503.         differences themselves. 
  1504.  
  1505.  
  1506. ΓòÉΓòÉΓòÉ 3.4. Internet Address Formats ΓòÉΓòÉΓòÉ
  1507.  
  1508. This section describes the address formats used in the internet domain. 
  1509.  
  1510.  
  1511. ΓòÉΓòÉΓòÉ 3.4.1. Internet Addressing ΓòÉΓòÉΓòÉ
  1512.  
  1513. Internet protocol (IP) addresses are 32-bit values that represent a network 
  1514. interface.  Every internet address within an administered internet (AF_INET) 
  1515. communication domain must be unique. A host can have as many internet addresses 
  1516. as it has network interfaces. For more information about internet address 
  1517. formats, see Internetworking with TCP/IP Volume I:  Principles, Protocols, and 
  1518. Architectures, and Volume II:  Implementation and Internals. 
  1519.  
  1520. Each internet host is assigned at least one unique internet address. This 
  1521. address is used by IP and other higher-level protocols. When a host is a 
  1522. gateway, it has more than one IP address.  Gateway hosts connect two or more 
  1523. physical networks and have one IP address per connected physical network. 
  1524.  
  1525. An internet address can be broken down into two pieces: 
  1526.  
  1527.      The network number 
  1528.  
  1529.       This identifies the physical network the address is associated with. 
  1530.      The host ID (or local address) 
  1531.  
  1532.       This identifies a specific host on that network. 
  1533.  
  1534.  All hosts on a single physical network have the same network number and can 
  1535.  communicate with each other directly, without going through intermediate 
  1536.  routers.  Hosts on disjoint physical networks have different network numbers 
  1537.  and must communicate through intermediate gateway hosts. 
  1538.  
  1539.  Dotted-Decimal Notation: A commonly used notation for internet host addresses 
  1540.  is the dotted-decimal notation, which divides the 32-bit address into four 
  1541.  8-bit fields. The value of each field is specified as a decimal number, and 
  1542.  the fields are separated by periods (for example, 10.2.0.52). 
  1543.  
  1544.  Address examples in this book use dotted-decimal notation in the following 
  1545.  forms: 
  1546.  
  1547.      nnn.lll.lll.lll 
  1548.      nnn.nnn.lll.lll 
  1549.      nnn.nnn.nnn.lll 
  1550.  
  1551.  where: 
  1552.  
  1553.  nnn     represents part or all of a network number. 
  1554.  lll     represents part or all of a local address. 
  1555.  
  1556.  Addressing within an Internet Domain: A socket address in an internet 
  1557.  communication domain is comprised of the five fields in the following 
  1558.  sockaddr_in structure: length, address family, port, an internet address, and 
  1559.  a reserved field. The sockaddr_in structure should be cleared before use. The 
  1560.  structure is located in the <NETINET\IN.H> header file: 
  1561.  
  1562.                struct in_addr {
  1563.                        u_long s_addr;
  1564.                };
  1565.  
  1566.                struct sockaddr_in {
  1567.                        u_char  sin_family;        /* AF_INET */
  1568.                        u_short sin_port;          /* port id */
  1569.                        struct  in_addr sin_addr;  /* address */
  1570.                        char    sin_zero[8];       /* not used */
  1571.                };
  1572.  
  1573.  The sin_family field is AF_INET. 
  1574.  
  1575.  The sin_port field is the port number in network-byte order. On a bind () 
  1576.  call, you can set this field to 0 and Network Services chooses a port for the 
  1577.  socket.  On a connect() call, you must set sin_port to the port you want to 
  1578.  connect to. For more information on ports, see Ports. 
  1579.  
  1580.  The sin_addr field is the internet address represented in network-byte order. 
  1581.  When specified as a parameter to bind(), sin_addr is usually set to the 
  1582.  constant INADDR_ANY, as defined in the <NETINET\IN.H> file. This binds the 
  1583.  socket to any and all local internet addresses. By using INADDR_ANY, an 
  1584.  application can bind a socket without specifying the local internet address. 
  1585.  The constant INADDR_ANY also allows an application running on a host with 
  1586.  multiple interfaces (multihomed host) to receive UDP datagrams and TCP 
  1587.  connection requests arriving at any interface on a single socket. (The 
  1588.  application is not required to have one socket per interface, with each 
  1589.  interface bound to a specific internet address). 
  1590.  
  1591.  If you do not set sin_addr to INADDR_ANY, you must set it to a valid internet 
  1592.  address for the workstation where the application is running. 
  1593.  
  1594.  The sin_zero field is not used, and it should be set to 0 by the application 
  1595.  before passing the address structure to any sockets call. 
  1596.  
  1597.  
  1598. ΓòÉΓòÉΓòÉ 3.5. TCP/IP-specific Network Utility Routines ΓòÉΓòÉΓòÉ
  1599.  
  1600. The TCP/IP protocol provides a library, TCP32DLL, that can be used in addition 
  1601. to the protocol-independent SO32DLL library. This API provides a set of network 
  1602. utility routines to perform useful tasks such as internet address translation, 
  1603. domain name resolution, network-byte order translation, and access to the 
  1604. database of useful network information. This library can be used for the 
  1605. PF_INET protocol family only. Network utility routines are described in the 
  1606. following sections. 
  1607.  
  1608.  
  1609. ΓòÉΓòÉΓòÉ 3.5.1. Host Names Information ΓòÉΓòÉΓòÉ
  1610.  
  1611. The following calls are host-related: 
  1612.  
  1613.      gethostbyname() 
  1614.      gethostbyaddr() 
  1615.      sethostent() 
  1616.      gethostent() 
  1617.      endhostent() 
  1618.      gethostname() 
  1619.  
  1620.  The gethostbyname() call takes an internet host name and returns a hostent 
  1621.  structure, which contains the name of the host, aliases, host address family 
  1622.  and host address. The hostent structure is defined in the <NETDB.H> header 
  1623.  file. 
  1624.  
  1625.  The gethostbyaddr() call maps the internet host address into a hostent 
  1626.  structure. 
  1627.  
  1628.  The database for these calls is provided by the name server or the ETC\HOSTS 
  1629.  file if a name server is not present or is unable to resolve the host name. 
  1630.  
  1631.  The sethostent(), gethostent(), and endhostent() calls open, provide 
  1632.  sequential access to, and close the ETC\HOSTS file. 
  1633.  
  1634.  The gethostname() call gets the name for the local host machine. 
  1635.  
  1636.  
  1637. ΓòÉΓòÉΓòÉ 3.5.2. Network Names Information ΓòÉΓòÉΓòÉ
  1638.  
  1639. The following calls are network-related: 
  1640.  
  1641.      getnetbyname() 
  1642.      getnetbyaddr() 
  1643.      setnetent() 
  1644.      getnetent() 
  1645.      endnetent() 
  1646.  
  1647.  The getnetbyname() call takes a network name and returns a netent structure, 
  1648.  which contains the name of the network, aliases, network address family, and 
  1649.  network number.  The netent structure is defined in the <NETDB.H> header file. 
  1650.  
  1651.  The getnetbyaddr() call maps the network number into a netent structure. 
  1652.  
  1653.  The database for these calls is provided by the ETC\NETWORKS file. 
  1654.  
  1655.  The setnetent(), getnetent(), and endnetent() calls open, provide sequential 
  1656.  access to, and close the ETC\NETWORKS file. 
  1657.  
  1658.  
  1659. ΓòÉΓòÉΓòÉ 3.5.3. Protocol Names Information ΓòÉΓòÉΓòÉ
  1660.  
  1661. The following calls are protocol-related: 
  1662.  
  1663.      getprotobyname() 
  1664.      getprotobynumber() 
  1665.      setprotoent() 
  1666.      getprotoent() 
  1667.      endprotoent() 
  1668.  
  1669.  The getprotobyname() call takes the protocol name and returns a protoent 
  1670.  structure, which contains the name of the protocol, aliases, and protocol 
  1671.  number.  The protoent structure is defined in the <NETDB.H> header file. 
  1672.  
  1673.  The getprotobynumber() call maps the protocol number into a protoent 
  1674.  structure. 
  1675.  
  1676.  The database for these calls is provided by the ETC\PROTOCOL file. 
  1677.  
  1678.  The setprotoent(), getprotoent(), and endprotoent() calls open, provide 
  1679.  sequential access to, and close the ETC\PROTOCOL file. 
  1680.  
  1681.  
  1682. ΓòÉΓòÉΓòÉ 3.5.4. Service Names Information ΓòÉΓòÉΓòÉ
  1683.  
  1684. The following calls are service-related: 
  1685.  
  1686.      getservbyname() 
  1687.      getservbyport() 
  1688.      setservent() 
  1689.      getservent() 
  1690.      endservent() 
  1691.  
  1692.  The getservbyname() call takes the service name and protocol, and returns a 
  1693.  servent structure that contains the name of the service, aliases, port number, 
  1694.  and protocol.  The servent structure is defined in the <NETDB.H> header file. 
  1695.  
  1696.  The getservbyport() call maps the port number and protocol into a servent 
  1697.  structure. 
  1698.  
  1699.  The database for these calls is provided by the ETC\SERVICES file. 
  1700.  
  1701.  The setservent(), getservent(), and endservent() calls provide open, provide 
  1702.  sequential access to, and close the ETC\SERVICES file. 
  1703.  
  1704.  
  1705. ΓòÉΓòÉΓòÉ 3.5.5. Network-Byte Order Translation ΓòÉΓòÉΓòÉ
  1706.  
  1707. Internet domain ports and addresses are usually specified to calls using the 
  1708. network-byte ordering convention. The following are the network-byte order 
  1709. translation calls: 
  1710.  
  1711.      htonl() 
  1712.      htons() 
  1713.      ntohl() 
  1714.      ntohs() 
  1715.  
  1716.  The htonl() and htons() calls translate host-byte order to network-byte order 
  1717.  for long integers (32-bit) and short integers (16-bit). 
  1718.  
  1719.  The ntohl() and ntohs() calls translate network-byte order to host-byte order 
  1720.  for long integers (32-bit) and short integers (16-bit). 
  1721.  
  1722.  
  1723. ΓòÉΓòÉΓòÉ 3.5.6. Internet Address Manipulation ΓòÉΓòÉΓòÉ
  1724.  
  1725. The following calls convert internet addresses and decimal notation, and 
  1726. manipulate the network number and local network address portions of an internet 
  1727. address: 
  1728.  
  1729.      inet_addr() 
  1730.      inet_network() 
  1731.      inet_ntoa() 
  1732.      inet_netof() 
  1733.      inet_lnaof() 
  1734.      inet_makeaddr() 
  1735.  
  1736.  The inet_addr() and inet_network() calls translate dotted-decimal notation to 
  1737.  a 32-bit internet address (network-byte order) or to a network number 
  1738.  (host-byte order, with zeros in the host part.) 
  1739.  
  1740.  The inet_ntoa() call translates 32-bit internet address (network-byte order) 
  1741.  to dotted-decimal notation. 
  1742.  
  1743.  The inet_netof() and inet_lnaof() calls extract the network number (host-byte 
  1744.  order) or the local network address (host-byte order) from a 32-bit internet 
  1745.  address (network-byte order). 
  1746.  
  1747.  The inet_makeaddr() call constructs internet address (network-byte order) from 
  1748.  network number and local network address. 
  1749.  
  1750.  
  1751. ΓòÉΓòÉΓòÉ 3.5.7. Domain Name Resolution ΓòÉΓòÉΓòÉ
  1752.  
  1753. Domain name resolution calls are used to resolve the symbolic host name into an 
  1754. internet address and to extract more information about the host from the 
  1755. database. 
  1756.  
  1757. The resolution calls determine whether the name server is present by 
  1758. referencing the ETC\RESOLV file.  To resolve a name with no name server 
  1759. present, the resolution calls check the ETC\HOSTS file for an entry that maps 
  1760. the name to an address.  To resolve a name in a name server network, the 
  1761. resolution calls query the domain name server database.  If this query fails, 
  1762. the calls then check for an entry in the local ETC\HOSTS file. 
  1763.  
  1764. The following resolution calls are used to make, send, and interpret packets 
  1765. for name servers in the internet domain: 
  1766.  
  1767.      res_mkquery() 
  1768.      res_send() 
  1769.      res_init() 
  1770.      dn_comp() 
  1771.      dn_expand() 
  1772.  
  1773.  
  1774. ΓòÉΓòÉΓòÉ 3.5.8. Ports ΓòÉΓòÉΓòÉ
  1775.  
  1776. A port is used to differentiate between different applications on a host using 
  1777. the same protocol (TCP or UDP).  It is an additional qualifier used by Network 
  1778. Services to get data to the correct application. Physically, a port is a 16-bit 
  1779. integer.  Some ports are reserved for particular applications and are called 
  1780. well-known ports. Well-Known Port Assignments contains the well-known port 
  1781. assignments list. 
  1782.  
  1783.  
  1784. ΓòÉΓòÉΓòÉ 4. Sockets over Local IPC ΓòÉΓòÉΓòÉ
  1785.  
  1786. The sockets over the Local IPC domain allow the programmer to communicate 
  1787. between applications on the same machine using the sockets API. Local IPC 
  1788. sockets are not bound to a network protocol, but rather use the underlying host 
  1789. facilities to provide high performance IPC. 
  1790.  
  1791. This section includes: 
  1792.  
  1793.      Getting Started with Sockets Over Local IPC 
  1794.      Local IPC Address Format 
  1795.  
  1796.  
  1797. ΓòÉΓòÉΓòÉ 4.1. Getting Started with Sockets Over Local IPC ΓòÉΓòÉΓòÉ
  1798.  
  1799. This section provides some basic information for getting started with sockets 
  1800. over Local IPC: 
  1801.  
  1802.      Use AF_OS/2  or AF_UNIX for the protocol family. 
  1803.  
  1804.      Use AF_OS/2, AF_LOCAL, or AF_UNIX for the address family. 
  1805.  
  1806.      The following socket types are supported for the Local IPC domain: 
  1807.  
  1808.         -  Datagram (SOCK_DGRAM) 
  1809.         -  Stream (SOCK_STREAM) 
  1810.  
  1811.       The socket type is passed as a parameter to the socket() call. For 
  1812.       additional information, refer to Socket Types and general socket 
  1813.       programming concepts in Programming with Sockets. 
  1814.  
  1815.      A unique text string is used as a name.  Refer to the discussion of 
  1816.       sun_path in the following section for additional details. 
  1817.  
  1818.      If a connect() socket call is received without an explicit bind(), an 
  1819.       implicit bind is automatically performed.  In this case, the application 
  1820.       does not care about its own name and a unique Local IPC name is generated 
  1821.       by Network Services. You can retrieve the Local IPC name by using the 
  1822.       getsockname() call. 
  1823.  
  1824.  
  1825. ΓòÉΓòÉΓòÉ 4.2. Local IPC Address Format ΓòÉΓòÉΓòÉ
  1826.  
  1827. The Local IPC address format is comprised of the three fields in the following 
  1828. sockaddr_un structure: length, address family, and the path name. The structure 
  1829. is located in the <SYS\UN.H> header file: 
  1830.  
  1831.              struct sockaddr_un {
  1832.                  u_char sun_family;         /* AF_OS2, AF_LOCAL, or AF_UNIX */
  1833.                  char   sun_path[108];      /* path name */
  1834.              };
  1835.  
  1836. The sun_family field is set to AF_OS2, AF_LOCAL, or AF_UNIX. 
  1837.  
  1838. The sun_path field is the OS/2 Warp Connect file and path name to be used as 
  1839. the address of the Local IPC socket. Each address is a combination of address 
  1840. family (sun_family) and a character string (sun_path) containing no more than 
  1841. 108 characters. Each socket must use a unique character string as its local 
  1842. name. 
  1843.  
  1844.  
  1845. ΓòÉΓòÉΓòÉ 5. Sockets over NetBIOS ΓòÉΓòÉΓòÉ
  1846.  
  1847. This section discusses using sockets over the NetBIOS communication domain.  In 
  1848. this domain, each application assigns itself one or more NetBIOS names for each 
  1849. adapter.  The NetBIOS protocol maintains a table of the names that a node is 
  1850. known by on the network.  NetBIOS supports two types of names: unique and 
  1851. group.  When the name is unique, the application binds the name and NetBIOS 
  1852. checks the network to ensure that the name is not already being used as a 
  1853. unique name. When using group names, NetBIOS supports multicast by allowing 
  1854. applications to bind to a group name and communicate. 
  1855.  
  1856. This section includes: 
  1857.  
  1858.      Getting Started with Sockets Over NetBIOS 
  1859.      NetBIOS Address Format 
  1860.  
  1861.  
  1862. ΓòÉΓòÉΓòÉ 5.1. Getting Started with Sockets Over NetBIOS ΓòÉΓòÉΓòÉ
  1863.  
  1864. This section provides some basic information for getting started with sockets 
  1865. over NetBIOS: 
  1866.  
  1867.      Use AF_NETBIOS or AF_NB for the protocol family. 
  1868.  
  1869.      Use AF_NETBIOS or AF_NB for the address family. 
  1870.  
  1871.      The following socket types are supported for the NetBIOS domain: 
  1872.  
  1873.         -  Datagram (SOCK_DGRAM) 
  1874.         -  Sequenced packet (SOCK_SEQPACKET) 
  1875.         -  Stream packet (SOCK_STREAM) 
  1876.  
  1877.       The socket type is passed as a parameter to the socket() call. For 
  1878.       additional information, refer to Socket Types and general socket 
  1879.       programming concepts in Programming with Sockets. 
  1880.  
  1881.      If a connect() socket call is received without an explicit bind(), an 
  1882.       implicit bind is automatically performed.  In this case, the application 
  1883.       does not care about its own name and a unique NetBIOS name is generated 
  1884.       by Network Services. 
  1885.  
  1886.      Applications using the NetBIOS communication domain can use sockets in 
  1887.       both a connection-oriented (sequenced packet) and connectionless 
  1888.       (datagram) mode. For additional information, refer to Connection Modes. 
  1889.  
  1890.      A NetBIOS application on one workstation can use sockets to communicate 
  1891.       with an NCB NetBIOS application on a different workstation. 
  1892.  
  1893.  
  1894. ΓòÉΓòÉΓòÉ 5.2. NetBIOS Address Format ΓòÉΓòÉΓòÉ
  1895.  
  1896. The NetBIOS address format is comprised of the six fields in the following 
  1897. sockaddr_nb structure: length, address family, address type, a reserved field, 
  1898. adapter number, and NetBIOS name. This structure is located in the <NETNB\NB.H> 
  1899. header file: 
  1900.  
  1901.              struct      sockaddr_nb {
  1902.                  u_char   snb_family;               /* AF_NetBIOS */
  1903.                  short    snb_type;                 /* 0=>unique or 1=>multicast */
  1904.                  char     snb_nbnetid[NB_NETIDLEN]; /* NetBIOS NetID */
  1905.                  unsigned short snb_adapter;        /* adapter number */
  1906.                  char     snb_name[NAMELEN];        /* NetBIOS name */
  1907.              }
  1908.  
  1909. The snb_family field is set to AF_NETBIOS or AF_NB. 
  1910.  
  1911. The address type field (snb_type) is used to specify the name as either a 
  1912. unique (NB_UNIQUE) or a group (NB_GROUP) name. 
  1913.  
  1914. The snb_adapter field contains the adapter number that the name is associated 
  1915. with. The adapter number must be a numeric value in the range 0-255. 
  1916.  
  1917. The snb_name field contains the 16-byte NetBIOS name. 
  1918.  
  1919. If a connect() socket call is received without an explicit bind(), an implicit 
  1920. bind is automatically performed.  In this case, the application does not care 
  1921. about its own name and is asking Network Services to select one for it.  A 
  1922. NetBIOS name is generated for this socket by converting the 6-byte MAC address 
  1923. to an ASCII hexadecimal string, and is postpended with a 2-byte number that 
  1924. increments after each use. You can retrieve the NetBIOS name by using the 
  1925. getsockname() call. 
  1926.  
  1927. Note that for the NetBIOS domain, more than one socket can be bound to the same 
  1928. local address to establish multiple connections to one or more remote 
  1929. destinations. To enable this feature, the socket option SO_REUSEADDR must be 
  1930. set.  See setsockopt(). In addition, you can bind more than one address to the 
  1931. same adapter. 
  1932.  
  1933.  
  1934. ΓòÉΓòÉΓòÉ 6. Protocol-Independent C Sockets API ΓòÉΓòÉΓòÉ
  1935.  
  1936. The following table briefly describes each protocol-independent socket call 
  1937. supported by MPTS and identifies the location in the book where you can find 
  1938. the syntax, parameters, and other appropriate information. The socket calls 
  1939. described in this section can be used to access services for all protocols: 
  1940.  
  1941. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  1942. Γöé Table 9. Protocol-Independent Sockets API Quick Reference       Γöé
  1943. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1944. Γöé SOCKET CALL  Γöé DESCRIPTION                       Γöé
  1945. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1946. Γöé accept()   Γöé Accepts a connection request              Γöé
  1947. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1948. Γöé bind()    Γöé Binds a local name to the socket            Γöé
  1949. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1950. Γöé connect()   Γöé Requests a connection to another socket         Γöé
  1951. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1952. Γöé getpeername()Γöé Gets the name of the peer connected to socket      Γöé
  1953. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1954. Γöé getsockname()Γöé Gets the local socket name               Γöé
  1955. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1956. Γöé getsockopt() Γöé Gets the socket options associated with a socket    Γöé
  1957. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1958. Γöé ioctl()    Γöé Performs special operations on socket          Γöé
  1959. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1960. Γöé listen()   Γöé Completes binding so that a socket can accept con-   Γöé
  1961. Γöé        Γöé nections and creates a connection request queue for   Γöé
  1962. Γöé        Γöé incoming requests                    Γöé
  1963. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1964. Γöé psock_errno()Γöé Writes a short error message to the standard error   Γöé
  1965. Γöé        Γöé device                         Γöé
  1966. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1967. Γöé readv()    Γöé Receives data on a socket into a set of buffers     Γöé
  1968. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1969. Γöé recv()    Γöé Receives data on a connected socket           Γöé
  1970. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1971. Γöé recvfrom()  Γöé Receives data on a socket                Γöé
  1972. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1973. Γöé recvmsg()   Γöé Receives data and control information on a socket    Γöé
  1974. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1975. Γöé select()   Γöé Gets read, write, and exception status on a group of  Γöé
  1976. Γöé        Γöé sockets                         Γöé
  1977. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1978. Γöé send()    Γöé send()                         Γöé
  1979. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1980. Γöé sendmsg()   Γöé Sends data and control information on a socket     Γöé
  1981. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1982. Γöé sendto()   Γöé Sends data on a socket                 Γöé
  1983. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1984. Γöé setsockopt() Γöé Sets options associated with a socket          Γöé
  1985. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1986. Γöé shutdown()  Γöé Shuts down all or part of a full duplex connection   Γöé
  1987. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1988. Γöé sock_errno() Γöé Returns error code set by a socket call         Γöé
  1989. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1990. Γöé socket()   Γöé Creates an endpoint for communication and returns a   Γöé
  1991. Γöé        Γöé socket descriptor                    Γöé
  1992. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1993. Γöé soclose()   Γöé Shuts down a socket and frees resources allocated to  Γöé
  1994. Γöé        Γöé the socket                       Γöé
  1995. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  1996. Γöé writev()   Γöé Writes data from a set of specified buffers on a    Γöé
  1997. Γöé        Γöé socket                         Γöé
  1998. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  1999.  
  2000. Note:  If you are using the internet communications domain (PF_INET protocol 
  2001. family), you can use all APIs in the previous table and those in section TCP/IP 
  2002. Network Utility Routines.  All other communication domains can only use those 
  2003. APIs listed in the previous table. 
  2004.  
  2005.  
  2006. ΓòÉΓòÉΓòÉ 6.1. accept() ΓòÉΓòÉΓòÉ
  2007.  
  2008. Accepts a connection request from a remote host. 
  2009.  
  2010. #include <types.h>
  2011. #include <sys\socket.h>
  2012. #include <netinet\in.h>
  2013. #include <netnb\nb.h>
  2014. #include <sys\un.h>
  2015.  
  2016. int accept(s, name, namelen)
  2017. int s;
  2018. struct sockaddr *name;
  2019. int *namelen;
  2020.  
  2021.  Parameter      Description 
  2022.  
  2023.  s              Socket descriptor. 
  2024.  
  2025.  name           Pointer to a sockaddr structure that contains the socket 
  2026.                 address of the connection client when the accept() call 
  2027.                 returns. The format of name is determined by the communications 
  2028.                 domain where the client resides. This parameter can be NULL if 
  2029.                 the caller is not interested in the client address. 
  2030.  
  2031.  namelen        Must initially point to an integer that contains the size in 
  2032.                 bytes of the storage pointed to by name.  On return, that 
  2033.                 integer contains the size of the data returned in the storage 
  2034.                 pointed to by name. If name is NULL, namelen is ignored and can 
  2035.                 be NULL. 
  2036.  
  2037.  Description:  This call is used by a server acting in a connection-oriented 
  2038.  mode to accept a connection request from a client.  The call accepts the first 
  2039.  connection on its queue of pending connection requests. The accept() call 
  2040.  creates a new socket descriptor with the same properties as s and returns it 
  2041.  to the caller. The new socket descriptor cannot be used to accept new 
  2042.  connections. The original socket, s, remains available to accept more 
  2043.  connection requests. 
  2044.  
  2045.  If the queue has no pending connection requests, accept() blocks the caller 
  2046.  unless s is in nonblocking mode.  If no connection requests are queued and s 
  2047.  is in nonblocking mode, accept() returns -1 and sets the return code to 
  2048.  SOCEWOULDBLOCK. 
  2049.  
  2050.  The s parameter must be a socket descriptor created with the socket() call. 
  2051.  It is usually bound to an address with the bind() call and must be made 
  2052.  capable of accepting connections with the listen() call.  The listen() call 
  2053.  marks the socket as one that accepts connections and allocates a queue to hold 
  2054.  pending connection requests. The listen() call allows the caller to place an 
  2055.  upper boundary on the size of the queue. 
  2056.  
  2057.  The name parameter is a pointer to a sockaddr structure where the connection 
  2058.  requester address is placed. The name parameter is optional and can be set to 
  2059.  be the NULL pointer.  If set to NULL, the requester address is not copied into 
  2060.  the sockaddr structure. The exact format of name depends on the communications 
  2061.  domain where the communication request originated. For example, if the 
  2062.  connection request originated in the internet domain, name points to a 
  2063.  sockaddr_in structure as defined in the header file <NETINET\IN.H>. 
  2064.  
  2065.  The namelen parameter is used only if name is not NULL. Before calling 
  2066.  accept(), you must set the integer pointed to by namelen to the size, in 
  2067.  bytes, of the sockaddr structure pointed to by name. On successful return, the 
  2068.  integer pointed to by namelen contains the actual number of bytes copied into 
  2069.  the sockaddr structure. If the sockaddr structure is not large enough to hold 
  2070.  the address, up to namelen bytes of the requester address are copied. 
  2071.  
  2072.  This call is used only with SOCK_STREAM or SOCK_SEQPACKET sockets. You cannot 
  2073.  screen requesters without calling accept().  The application cannot tell the 
  2074.  Network Services software which requesters to accept connections from.  The 
  2075.  caller can, however, choose to close a connection immediately after 
  2076.  discovering the identity of the requester. 
  2077.  
  2078.  The select() call can be used to check the socket for incoming connection 
  2079.  requests. 
  2080.  
  2081.  Return and sock_errno() Values:  A non-negative socket descriptor indicates 
  2082.  success; the return value -1 indicates an error. You can get the specific 
  2083.  error code by calling sock_errno() or psock_errno(). 
  2084.  
  2085.            sock_errno() Value     Description 
  2086.  
  2087.       SOCECOMMSYS                 Internal communications error.  Contact IBM 
  2088.                                   Service. 
  2089.  
  2090.       SOCEFAULT                   Using name and namelen results in an attempt 
  2091.                                   to copy the address into a portion of the 
  2092.                                   caller address space where information cannot 
  2093.                                   be written. 
  2094.  
  2095.       SOCEINVAL                   Listen() was not called for socket s. 
  2096.  
  2097.       SOCENOBUFS                  Insufficient buffer space is available to 
  2098.                                   create the new socket. 
  2099.  
  2100.       SOCENOTSOCK                 The s parameter is not a valid socket 
  2101.                                   descriptor. 
  2102.  
  2103.       SOCEOPNOTSUPP               The s parameter is not connection-oriented. 
  2104.  
  2105.       SOCEWOULDBLOCK              The s parameter is in nonblocking mode and no 
  2106.                                   connections are on the queue. 
  2107.  
  2108.  Examples:  The following are two examples of the accept() call.  In the first, 
  2109.  the caller wants to have the requester address returned. In the second, the 
  2110.  caller does not want to have the requester address returned. 
  2111.  
  2112.   int clientsocket;
  2113.   int s;
  2114.   struct sockaddr clientaddress;
  2115.   int addrlen;
  2116.   int accept(int s, struct sockaddr *addr, int *addrlen); /* extracted from sys\socket.h */
  2117.   /* socket(), bind(), and listen() have been called */
  2118.   /* EXAMPLE 1: I want the address now */
  2119.  
  2120.   addrlen = sizeof(clientaddress);
  2121.   clientsocket = accept(s, &clientaddress, &addrlen);
  2122.   /* EXAMPLE 2: I can get the address later using getpeername() */
  2123.   clientsocket = accept(s, (struct sockaddr *) 0, (int *) 0);
  2124.  
  2125.  
  2126. ΓòÉΓòÉΓòÉ 6.2. bind() ΓòÉΓòÉΓòÉ
  2127.  
  2128. Binds a local name to the socket. 
  2129.  
  2130. #include <types.h>
  2131. #include <sys\socket.h>
  2132.  
  2133. int bind(s, name, namelen)
  2134. int s;
  2135. struct sockaddr *name;
  2136. int namelen;
  2137.  
  2138.  Parameter      Description 
  2139.  
  2140.  s              Socket descriptor returned by a previous call to socket(). 
  2141.  
  2142.  name           Pointer to a sockaddr structure containing the name that is to 
  2143.                 be bound to s. 
  2144.  
  2145.  namelen        Size in bytes of the sockaddr structure pointed to by name. 
  2146.  
  2147.  Description:  This call binds a unique local name to the socket with 
  2148.  descriptor s. After calling socket(), a descriptor does not have a name 
  2149.  associated with it.  However, it does belong to a particular protocol family 
  2150.  as specified when socket() is called. The exact format of a name depends on 
  2151.  the protocol family. The bind() procedure also allows servers to specify the 
  2152.  network interfaces the program wants to receive data from. 
  2153.  
  2154.  The format of name is determined by the domain where communication occurs. If 
  2155.  the caller is not interested in its own address, set the protocol-dependent 
  2156.  fields within the sockaddr structure to NULL and Network Services assigns an 
  2157.  address for it.  This enables data to be received from any address, sometimes 
  2158.  referred to as wildcard addressing. Data cannot be received from any address 
  2159.  using raw sockets. 
  2160.  
  2161.  In the internet domain, set sin_port in the sockaddr_in structure to a 
  2162.  specific port or to 0, which indicates that Network Services should select 
  2163.  
  2164.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  2165.  return value -1 indicates an error. You can get the specific error code by 
  2166.  calling sock_errno() or psock_errno(). 
  2167.  
  2168.  
  2169.            sock_errno() Value      Description 
  2170.  
  2171.       SOCEADDRINUSE                The address is already in use.  See the 
  2172.                                    SO_REUSEADDR option described under 
  2173.                                    getsockopt() and the SO_REUSEADDR option 
  2174.                                    described under setsockopt(). 
  2175.  
  2176.       SOCEADDRNOTAVAIL             The address specified is not valid on this 
  2177.                                    host.  For example, the internet address 
  2178.                                    does not specify a valid network interface. 
  2179.  
  2180.       SOCEAFNOSUPPORT              The address family is not supported. 
  2181.  
  2182.       SOCECOMMSYS                  Internal communications error.  Contact IBM 
  2183.                                    Service. 
  2184.  
  2185.       SOCEFAULT                    Using name and namelen results in an attempt 
  2186.                                    to read from a non-readable portion of the 
  2187.                                    application address space. 
  2188.  
  2189.       SOCEINVAL                    The socket is already bound to an address, 
  2190.                                    or namelen is not the expected length. 
  2191.  
  2192.       SOCENOBUFS                   No buffer space is available. 
  2193.  
  2194.       SOCENOTSOCK                  The s parameter is not a valid socket 
  2195.                                    descriptor. 
  2196.  
  2197.  Examples: 
  2198.  
  2199.  Note the following about the bind() call examples: 
  2200.  
  2201.      For the internet examples, put the internet address and port in 
  2202.       network-byte order. To put the port into network-byte order, use the 
  2203.       htons() utility routine to convert a short integer from host-byte order 
  2204.       to network-byte order. 
  2205.  
  2206.      For the internet examples, set the address field using the inet_addr() 
  2207.       utility routine, which takes a character string representing the 
  2208.       dotted-decimal address of an interface and returns the binary internet 
  2209.       address representation in network-byte order. 
  2210.  
  2211.      Zero the structure before using it to ensure that the name requested does 
  2212.       not set any reserved fields. 
  2213.  
  2214.  See connect() for examples of how a client can connect to servers. 
  2215.  
  2216.   int rc;
  2217.   int s;
  2218.   struct sockaddr_in myname;
  2219.   int bind(int s, struct sockaddr *name, int namelen); /* extracted from sys\socket.h */
  2220.  
  2221.   /* Bind to a specific interface in the internet domain */
  2222.   /* clear the structure */
  2223.   memset(&myname, 0, sizeof(myname));
  2224.   myname.sin_family = AF_INET;
  2225.   myname.sin_addr = inet_addr("129.5.24.1"); /* specific interface */
  2226.   myname.sin_port = htons(1024);
  2227.   .
  2228.   .
  2229.   .
  2230.   rc = bind(s, (struct sockaddr *) &myname, sizeof(myname));
  2231.  
  2232.   /* Bind to all internet network interfaces on the system */
  2233.   /* clear the structure */
  2234.   memset(&myname, 0, sizeof(myname));
  2235.   myname.sin_family = AF_INET;
  2236.   myname.sin_addr.s_addr = INADDR_ANY; /* all interfaces */
  2237.   myname.sin_port = htons(1024);
  2238.   .
  2239.   .
  2240.   .
  2241.   rc = bind(s, (struct sockaddr *) &myname, sizeof(myname));
  2242.  
  2243.   /* Bind to a specific interface in the internet domain.
  2244.      Let Network Services choose a port */
  2245.   /* clear the structure */
  2246.   memset(&myname, 0, sizeof(myname));
  2247.   myname.sin_family = AF_INET;
  2248.   myname.sin_addr = inet_addr("129.5.24.1"); /* specific interface */
  2249.   myname.sin_port = 0;
  2250.   .
  2251.   .
  2252.   .
  2253.   rc = bind(s, (struct sockaddr *) &myname, sizeof(myname));
  2254.  
  2255.   /* Bind to a unique NetBIOS name on adapter 0 */
  2256.   struct sockaddr_nb nbname;
  2257.   memset(&nbname, 0, sizeof(nbname));
  2258.   nbname.snb_family = AF_NB;
  2259.   nbname.snb_type = NB_UNIQUE;
  2260.   nbname.snb.netid[b]=0;
  2261.   nbname.snb_adapter = 0;
  2262.   strcpy(nbname.snb_name, "NBSERVER");    /* Note that a NetBIOS name is
  2263.                                              16 bytes long.  In this example,
  2264.                                              the last 8 bytes are filled
  2265.                                              with zeros.                    */
  2266.  
  2267.   .
  2268.   .
  2269.   .
  2270.   rc = bind(s, (struct sockaddr *) &nbname, sizeof(nbname));
  2271.  
  2272.  
  2273. ΓòÉΓòÉΓòÉ 6.3. connect() ΓòÉΓòÉΓòÉ
  2274.  
  2275. Requests a connection to another socket. 
  2276.  
  2277. #include <types.h>
  2278. #include <sys\socket.h>
  2279.  
  2280. int connect(s, name, namelen)
  2281. int s;
  2282. struct sockaddr *name;
  2283. int namelen;
  2284.  
  2285.  Parameter      Description 
  2286.  
  2287.  s              Socket descriptor used to originate the connection request. 
  2288.  
  2289.  name           Pointer to a sockaddr structure containing the address of the 
  2290.                 socket to which a connection is attempted. 
  2291.  
  2292.  namelen        Size in bytes of the sockaddr structure pointed to by name. 
  2293.  
  2294.  Description: 
  2295.  
  2296.  Stream or sequenced packet sockets: The connect() call performs two tasks when 
  2297.  called for a stream or sequenced packet socket:  1) it completes the binding 
  2298.  if necessary for a socket, and 2) it attempts to create a connection between 
  2299.  two sockets. 
  2300.  
  2301.  This call is used by the client side of socket-based applications to establish 
  2302.  a connection with a server. The server must have a passive open pending. This 
  2303.  means the server must successfully call bind() and listen(). Otherwise, 
  2304.  connect() returns -1 and the error value is set to SOCECONNREFUSED. 
  2305.  
  2306.  In the internet communication domain, a timeout occurs if a connection to the 
  2307.  remote host is not successful within 75 seconds (1 minute and 15 seconds). 
  2308.  There is no timeout for Local IPC. In the NetBIOS communication domain, a 
  2309.  timeout occurs if a connection to the host is not successful within the time 
  2310.  defined by the NetBIOS protocol parameters Transmit Timer multiplied by 
  2311.  Transmit Retry. 
  2312.  
  2313.  If s is in blocking mode, the connect() call blocks the caller until the 
  2314.  connection is established or until an error is received.  If the socket is in 
  2315.  nonblocking mode and the connection was successfully initiated, connect() 
  2316.  returns -1 and sets the error value to SOCEINPROGRESS. The caller can test the 
  2317.  completion of the connection setup by calling: 1) select() to test for the 
  2318.  ability to write to the socket, and 2) getsockopt() with option SO_ERROR to 
  2319.  test if the connection succeeded. 
  2320.  
  2321.  Stream or sequenced packet sockets can call connect() only once. Even if the 
  2322.  connection attempt fails, you must use soclose() to close the socket and use 
  2323.  socket() to create a new socket before trying to connect again. 
  2324.  
  2325.  Datagram or raw sockets: The connect() call specifies the destination peer 
  2326.  address when called for a datagram or raw socket. Normally, datagram and raw 
  2327.  sockets use connectionless data transfer calls such as sendto() and 
  2328.  recvfrom().  However, applications can call connect() to specify and store the 
  2329.  destination peer address for this socket.  This identifies which address to 
  2330.  send data to on this socket. This method of communication allows datagram and 
  2331.  raw sockets to be connected. However, data is still not guaranteed to be 
  2332.  delivered. Thus, the normal characteristics of connectionless mode sockets is 
  2333.  maintained. The address is remembered until another connect() call is made. 
  2334.  This permits the use of readv(), recv(), send(), and writev(), which are 
  2335.  usually reserved for connection-oriented sockets. The application can still 
  2336.  use sendto(), recvfrom(), sendmsg(), and recvmsg().  The advantage of calling 
  2337.  connect() and being connected is that the destination peer address does not 
  2338.  have to be specified for all datagrams sent. Also, when a datagram socket is 
  2339.  connected, only datagrams from the connected peer are delivered to the socket. 
  2340.  
  2341.  Datagram and raw sockets can call connect() multiple times. The application 
  2342.  can reset their destination address by specifying a new address on the 
  2343.  connect() call. In addition, the socket can be returned to operate in a 
  2344.  connectionless mode by calling connect() with a null destination address. The 
  2345.  null address is created by zeroing the sockaddr structure and setting only the 
  2346.  address family field. The call to connect returns -1, indicating that the 
  2347.  connection to the null address cannot be established.  Calling sock_errno() 
  2348.  returns SOCEADDRNOTAVAIL. For more information on connecting datagram sockets, 
  2349.  see "Description" for sendto(). 
  2350.  
  2351.  Examples: 
  2352.  
  2353.  Note the following about these connect() call examples: 
  2354.  
  2355.      For the internet examples, put the internet address and port in 
  2356.       network-byte order.  To put the port into network-byte order, use the 
  2357.       htons() utility routine to convert a short integer from host-byte order 
  2358.       to network-byte order. 
  2359.  
  2360.      For the internet examples, set the address field using the inet_addr() 
  2361.       utility routine, which takes a character string representing the 
  2362.       dotted-decimal address of an interface and returns the binary internet 
  2363.       address representation in network-byte order. 
  2364.  
  2365.      To ensure that the name requested does not set any reserved fields, zero 
  2366.       the structure before using it . 
  2367.  These examples could be used to connect to the servers shown in the examples 
  2368.  listed for bind(). 
  2369.  
  2370.   int s;
  2371.   struct sockaddr_in servername;
  2372.   int rc;
  2373.   int connect(int s, struct sockaddr *name, int namelen); /* extracted from sys\socket.h */
  2374.  
  2375.   /* Connect to server bound to a specific interface in the internet domain */
  2376.   /* clear the structure */
  2377.   memset(&servername, 0, sizeof(servername));
  2378.   servername.sin_family = AF_INET;
  2379.   servername.sin_addr.s_addr = inet_addr("129.5.24.1"); /* specific interface */
  2380.   servername.sin_port = htons(1024); /* set to the port to which */
  2381.                                              /* the server is bound */
  2382.   .
  2383.   .
  2384.   .
  2385.   rc = connect(s, (struct sockaddr *) &servername, sizeof(servername));
  2386.  
  2387.   /* Connect to a NetBIOS server */
  2388.   struct sockaddr_nb nbservername;
  2389.   memset(&nbservername, 0, sizeof(nbservername));
  2390.   nbservername.snb_family = AF_NB;
  2391.   nbservername.snb_type = NB_UNIQUE;
  2392.   nbname.snb_nbnetID[0]v= "0";
  2393.   strcpy(nbservername.snb_name, "NBSERVER");
  2394.   .
  2395.   .
  2396.   .
  2397.   rc = connect(s, (struct sockaddr *) &nbservername, sizeof(nbservername));
  2398.  
  2399.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  2400.  return value -1 indicates an error. You can get the specific error code by 
  2401.  calling sock_errno() or psock_errno(). 
  2402.  
  2403.  
  2404.            sock_errno() Value      Description 
  2405.  
  2406.       SOCEADDRNOTAVAIL             The calling host attempted to connect to 
  2407.                                    port 0, or no local address exists for the 
  2408.                                    connecting socket to be implicitly bound to 
  2409.                                    at the time of the connect. 
  2410.  
  2411.       SOCEAFNOSUPPORT              The address family is not supported. 
  2412.  
  2413.       SOCEALREADY                  The socket s is marked nonblocking, and a 
  2414.                                    previous connection attempt has not 
  2415.                                    completed. 
  2416.  
  2417.       SOCECOMMSYS                  Internal communications error.  Contact IBM 
  2418.                                    Service. 
  2419.  
  2420.       SOCECONNREFUSED              The connection request was rejected by the 
  2421.                                    destination host. This error code implies 
  2422.                                    that the connection request was received at 
  2423.                                    the destination host but a socket bound to 
  2424.                                    the destination port does not exist. 
  2425.  
  2426.       SOCEFAULT                    Using name and namelen results in an attempt 
  2427.                                    to read from a non-readable portion of the 
  2428.                                    application address space. 
  2429.  
  2430.       SOCEINPROGRESS               The socket s is marked nonblocking, and the 
  2431.                                    connection cannot be completed immediately. 
  2432.                                    The SOCEINPROGRESS value does not indicate 
  2433.                                    an error condition. 
  2434.  
  2435.       SOCEINVAL                    The namelen parameter is not a valid length. 
  2436.                                    For a stream socket, a previous connection 
  2437.                                    was refused or received SOCEALREADY and then 
  2438.                                    failed. 
  2439.  
  2440.       SOCEISCONN                   The socket s is already connected. 
  2441.  
  2442.       SOCENETUNREACH               The network cannot be reached from this 
  2443.                                    host. 
  2444.  
  2445.       SOCENOBUFS                   No buffer space is available. 
  2446.  
  2447.       SOCENOTSOCK                  The s parameter is not a valid socket 
  2448.                                    descriptor. 
  2449.  
  2450.       SOCETIMEDOUT                 The connection establishment timed out 
  2451.                                    before a connection was made. This error 
  2452.                                    code usually implies that the connection 
  2453.                                    request is not reaching the destination (or 
  2454.                                    the destination's reply is not reaching the 
  2455.                                    requester).  This error is also returned if 
  2456.                                    the connection request does reach the 
  2457.                                    destination, and a socket is bound to the 
  2458.                                    specified destination port, but listen() has 
  2459.                                    not been issued for that socket. 
  2460.  
  2461.  
  2462. ΓòÉΓòÉΓòÉ 6.4. getpeername() ΓòÉΓòÉΓòÉ
  2463.  
  2464. Gets the name of the peer connected to socket. 
  2465.  
  2466. #include <types.h>
  2467. #include <sys\socket.h>
  2468.  
  2469. int getpeername(s, name, namelen)
  2470. int s;
  2471. struct sockaddr *name;
  2472. int *namelen;
  2473.  
  2474.  Parameter      Description 
  2475.  
  2476.  s              Socket descriptor. 
  2477.  
  2478.  name           Pointer to a sockaddr structure.  The name of the peer 
  2479.                 connected to socket s is returned. The exact format of name is 
  2480.                 determined by the domain where communication occurs. 
  2481.  
  2482.  namelen        Pointer to the size in bytes of the sockaddr structure pointed 
  2483.                 to by name. 
  2484.  
  2485.  Description:  This call returns the name of the peer connected to socket s. 
  2486.  The namelen parameter must be initialized to indicate the size of the space 
  2487.  pointed to by name. On return, namelen is set to the size of the peer name 
  2488.  copied. If the sockaddr structure is too small, the peer name is truncated. 
  2489.  
  2490.  This call operates only on connected sockets. 
  2491.  
  2492.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  2493.  return value -1 indicates an error. You can get the specific error code by 
  2494.  calling sock_errno() or psock_errno(). 
  2495.  
  2496.  
  2497.            sock_errno() Value  Description 
  2498.  
  2499.       SOCECOMMSYS              Internal communications error.  Contact IBM 
  2500.                                Service. 
  2501.  
  2502.       SOCEFAULT                Using the name and namelen parameters as 
  2503.                                specified results in an attempt to access 
  2504.                                storage outside of the address space of the 
  2505.                                caller. 
  2506.  
  2507.       SOCENOBUFS               No buffer space is available. 
  2508.  
  2509.       SOCENOTCONN              The socket is not connected. 
  2510.  
  2511.       SOCENOTSOCK              The s parameter is not a valid socket 
  2512.                                descriptor. 
  2513.  
  2514.  
  2515. ΓòÉΓòÉΓòÉ 6.5. getsockname() ΓòÉΓòÉΓòÉ
  2516.  
  2517. Gets the local socket name. 
  2518.  
  2519. #include <types.h>
  2520. #include <sys\socket.h>
  2521.  
  2522. int getsockname(s, name, namelen)
  2523. int s;
  2524. struct sockaddr *name;
  2525. int *namelen;
  2526.  
  2527.  Parameter      Description 
  2528.  
  2529.  s              Socket descriptor. 
  2530.  
  2531.  name           Pointer to a sockaddr structure. The name of s is returned. 
  2532.  
  2533.  namelen        Pointer to the size in bytes of the sockaddr structure pointed 
  2534.                 to by name. 
  2535.  
  2536.  Description:  This call returns the name for the socket specified by the s 
  2537.  parameter in the structure pointed to by the name parameter.  It returns the 
  2538.  address to the socket that has been bound.  If the socket is not bound to an 
  2539.  address, the call returns with the family set and the rest of the structure is 
  2540.  set to zero. For example, an unbound socket in the internet domain causes the 
  2541.  name to point to a sockaddr_in structure with the sin_family field set to 
  2542.  AF_INET and all other fields zeroed. 
  2543.  
  2544.  The namelen parameter must be initialized to indicate the size of the space 
  2545.  pointed to by name and is set to the size of the local name copied.  If the 
  2546.  sockaddr structure is too small, the local name is truncated. 
  2547.  
  2548.  Sockets are explicitly assigned a name after a successful call to bind(). 
  2549.  Stream and sequenced packet sockets are implicitly assigned a name after a 
  2550.  successful call to connect() or accept() if bind() was not called. 
  2551.  
  2552.  The getsockname() call is often used to discover the port assigned to a socket 
  2553.  after the socket has been implicitly bound to a port.  For example, an 
  2554.  application can call connect() without previously calling bind(). In this 
  2555.  case, the connect() call completes the binding necessary by assigning a port 
  2556.  to the socket. 
  2557.  
  2558.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  2559.  return value -1 indicates an error. You can get the specific error code by 
  2560.  calling sock_errno() or psock_errno(). 
  2561.  
  2562.  
  2563.            sock_errno() Value Description 
  2564.  
  2565.       SOCECOMMSYS            Internal communications error.  Contact IBM 
  2566.                              Service. 
  2567.  
  2568.       SOCEFAULT              Using the name and namelen parameters as specified 
  2569.                              results in an attempt to access storage outside of 
  2570.                              the address space of the caller. 
  2571.  
  2572.       SOCEINVAL              The socket received an error, such as a timed out 
  2573.                              connect. 
  2574.  
  2575.       SOCENOBUFS             No buffer space is available. 
  2576.  
  2577.       SOCENOTSOCK            The s parameter is not a valid socket descriptor. 
  2578.  
  2579.  
  2580. ΓòÉΓòÉΓòÉ 6.6. getsockopt() ΓòÉΓòÉΓòÉ
  2581.  
  2582. Gets the socket options associated with a socket. 
  2583.  
  2584. #include <types.h>
  2585. #include <sys\socket.h>
  2586.  
  2587. int getsockopt(s, level, optname, optval, optlen)
  2588. int s;
  2589. int level;
  2590. int optname;
  2591. char *optval;
  2592. int *optlen;
  2593.  
  2594.  Parameter      Description 
  2595.  
  2596.  s              Socket descriptor. 
  2597.  
  2598.  level          Specifies which option level is being queried for the specified 
  2599.                 optname. 
  2600.  
  2601.  optname        Name of a specified socket option. Only one option can be 
  2602.                 specified on a call. 
  2603.  
  2604.  optval         Pointer to buffer to receive the option data requested. 
  2605.  
  2606.  optlen         Pointer to the size of the buffer. 
  2607.  
  2608.  Description:  This call returns the value of a socket option at the socket or 
  2609.  protocol level. It can be called for sockets of all domain types. Some options 
  2610.  are supported only for specific socket types. You must specify the level of 
  2611.  the option and the name of the option to retrieve option values. The following 
  2612.  table lists the supported levels. 
  2613.  
  2614.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  2615.   Γöé Table 10. Supported Levels            Γöé
  2616.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2617.   Γöé SUPPORTED LEVEL    Γöé #DEFINE IN        Γöé
  2618.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2619.   Γöé SOL_SOCKET      Γöé <SYS\SOCKET.H>      Γöé
  2620.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2621.   Γöé IPPROTO_IP      Γöé <NETINET\IN.H>      Γöé
  2622.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2623.   Γöé IPPROTO_TCP      Γöé <NETINET\IN.H>      Γöé
  2624.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2625.   Γöé NBPROTO_NB      Γöé <NETNB\NB.H>       Γöé
  2626.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  2627.  
  2628.  The optval parameter is a pointer to the buffer where the option values are 
  2629.  returned. The optlen parameter must be initially set to the size of the buffer 
  2630.  before calling getsockopt().  On return, the optlen parameter is set to the 
  2631.  actual size of the data returned. For socket options that are boolean, the 
  2632.  option is enabled if optval is nonzero and disabled if optval is 0. 
  2633.  
  2634.  The following tables list the supported options for getsockopt() at each level 
  2635.  (SOL_SOCKET, IPPROTO_IP, IPPROTO_TCP, NBPROTO_NB). Detailed descriptions of 
  2636.  the options follow each table. 
  2637.  
  2638.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  2639.   Γöé Table 11. Supported getsockopt() Socket Options for SOL_SOCKET        Γöé
  2640.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2641.   Γöé         Γöé               Γöé  DOMAINS Γöé DATA  Γöé BOOLEAN  Γöé
  2642.   Γöé OPTION NAME   Γöé DESCRIPTION         Γöé   *   Γöé TYPE  Γöé OR VALUE Γöé
  2643.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2644.   Γöé SO_BROADCAST   Γöé allows sending of broad-  Γöé I, N   Γöé int   Γöé boolean  Γöé
  2645.   Γöé         Γöé cast messages        Γöé      Γöé     Γöé      Γöé
  2646.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2647.   Γöé SO_DEBUG     Γöé turns on recording of    Γöé I, L   Γöé int   Γöé boolean  Γöé
  2648.   Γöé         Γöé debugging information    Γöé      Γöé     Γöé      Γöé
  2649.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2650.   Γöé SO_DONTROUTE   Γöé bypasses routing tables   Γöé I, L   Γöé int   Γöé boolean  Γöé
  2651.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2652.   Γöé SO_ERROR     Γöé gets any pending error and Γöé I, L   Γöé int   Γöé value   Γöé
  2653.   Γöé         Γöé clear            Γöé      Γöé     Γöé      Γöé
  2654.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2655.   Γöé SO_KEEPALIVE   Γöé keeps connections alive   Γöé I     Γöé int   Γöé boolean  Γöé
  2656.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2657.   Γöé SO_LINGER    Γöé lingers on close if data  Γöé I     Γöé struct Γöé value   Γöé
  2658.   Γöé         Γöé present           Γöé      Γöé linger Γöé      Γöé
  2659.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2660.   Γöé SO_OOBINLINE   Γöé leaves received OOB data  Γöé I     Γöé int   Γöé boolean  Γöé
  2661.   Γöé         Γöé in-line           Γöé      Γöé     Γöé      Γöé
  2662.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2663.   Γöé SO_RCVBUF    Γöé receives buffer size    Γöé I, L, N  Γöé long  Γöé value   Γöé
  2664.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2665.   Γöé SO_RCVLOWAT   Γöé receives low-water mark   Γöé I, L   Γöé int   Γöé value   Γöé
  2666.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2667.   Γöé SO_RCVTIMEO   Γöé receives timeout      Γöé I, L, N  Γöé struct Γöé value   Γöé
  2668.   Γöé         Γöé               Γöé      Γöé timevalΓöé      Γöé
  2669.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2670.   Γöé SO_REUSEADDR   Γöé allows local address reuse Γöé I, N   Γöé int   Γöé boolean  Γöé
  2671.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2672.   Γöé SO_REUSEPORT   Γöé allows socket to reuse a  Γöé I     Γöé int   Γöé boolean  Γöé
  2673.   Γöé         Γöé local address and local   Γöé      Γöé     Γöé      Γöé
  2674.   Γöé         Γöé port            Γöé      Γöé     Γöé      Γöé
  2675.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2676.   Γöé SO_SNDBUF    Γöé sends buffer size      Γöé I, L, N  Γöé long  Γöé value   Γöé
  2677.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2678.   Γöé SO_SNDLOWAT   Γöé sends low-water mark    Γöé I, L   Γöé int   Γöé value   Γöé
  2679.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2680.   Γöé SO_SNDTIMEO   Γöé sends timeout        Γöé I, L, N  Γöé struct Γöé value   Γöé
  2681.   Γöé         Γöé               Γöé      Γöé timevalΓöé      Γöé
  2682.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2683.   Γöé SO_TYPE     Γöé gets socket type      Γöé I, L, N  Γöé int   Γöé value   Γöé
  2684.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2685.   Γöé NOTE:  * This column specifies I for internet, L for Local IPC, and N for  Γöé
  2686.   Γöé NetBIOS communication domains.                        Γöé
  2687.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  2688.  
  2689.  The following options are recognized for option level SOL_SOCKET: 
  2690.  
  2691.  
  2692.            Option                Description 
  2693.  
  2694.       SO_BROADCAST               (datagram sockets only) Retrieves the current 
  2695.                                  ability of the socket to broadcast messages. 
  2696.                                  If this option is enabled, it allows the 
  2697.                                  application to send broadcast messages over s, 
  2698.                                  if the interface specified in the destination 
  2699.                                  supports broadcasting of packets. 
  2700.  
  2701.       SO_DEBUG                   Retrieves the current ability for recording 
  2702.                                  debug information for a socket. 
  2703.  
  2704.       SO_DONTROUTE               Retrieves the current ability for the socket 
  2705.                                  to bypass routing. When this option is 
  2706.                                  enabled, it causes outgoing messages to bypass 
  2707.                                  the standard routing algorithm and be directed 
  2708.                                  to the appropriate network interface, 
  2709.                                  according to the network portion of the 
  2710.                                  destination address. When enabled, packets can 
  2711.                                  be sent to directly connected networks 
  2712.                                  (networks this host has an interface for) 
  2713.                                  only. 
  2714.  
  2715.       SO_ERROR                   Returns any pending error on the socket and 
  2716.                                  clears the error status.  It can be used to 
  2717.                                  check for asynchronous errors on connected 
  2718.                                  datagram sockets or for other asynchronous 
  2719.                                  errors (errors that are not returned 
  2720.                                  explicitly by one of the socket calls). 
  2721.  
  2722.       SO_KEEPALIVE               (stream sockets only) Retrieves the current 
  2723.                                  ability of the socket to send keepalive 
  2724.                                  packets. TCP uses a timer called the keepalive 
  2725.                                  timer.  This timer is used to monitor idle 
  2726.                                  connections that may have been disconnected 
  2727.                                  because of a peer crash or timeout. If this 
  2728.                                  option is set to ON, a keepalive packet is 
  2729.                                  periodically sent to the peer.  This is mainly 
  2730.                                  used to allow servers to close connections 
  2731.                                  that are no longer active as a result of 
  2732.                                  clients going away without properly closing 
  2733.                                  connections. 
  2734.  
  2735.       SO_LINGER                  (stream sockets only) Retrieves the current 
  2736.                                  ability of the socket to linger on close. When 
  2737.                                  this option is enabled, and data is present in 
  2738.                                  the socket's send buffer when soclose() is 
  2739.                                  called, the calling application is blocked in 
  2740.                                  soclose() until the data is transmitted or 
  2741.                                  until the linger timeout expires.  If the 
  2742.                                  linger timeout expires, the unsent data is 
  2743.                                  discarded, the connection is reset, and 
  2744.                                  soclose() returns -1 with an error value of 
  2745.                                  SOCEWOULDBLOCK.  Even though soclose() 
  2746.                                  returned an error, the socket is closed (no 
  2747.                                  further calls can be made for the socket). 
  2748.                                  Note that a linger timeout of zero results in 
  2749.                                  no lingering if unsent data exists.  A timeout 
  2750.                                  of zero expires immediately when the call is 
  2751.                                  issued, resulting in discarding any unsent 
  2752.                                  data and resetting the connection. 
  2753.  
  2754.                                  When this option is disabled (the default), 
  2755.                                  soclose() does not block when unsent data is 
  2756.                                  present at the time of the call. Rather, the 
  2757.                                  soclose() completes immediately and TCP 
  2758.                                  continues to attempt to send the remaining 
  2759.                                  data before closing the connection. The 
  2760.                                  application has no guarantee that the data is 
  2761.                                  sent, because errors encountered on the 
  2762.                                  connection after the socket is closed cannot 
  2763.                                  be reported to the application. 
  2764.  
  2765.       SO_OOBINLINE               (stream sockets only) Retrieves the current 
  2766.                                  ability of the socket to receive out-of-band 
  2767.                                  data. When this option is enabled, it causes 
  2768.                                  out-of-band data to be placed in the normal 
  2769.                                  data input queue as it is received, making it 
  2770.                                  available to recv(), and recvfrom() without 
  2771.                                  having to specify the MSG_OOB flag in those 
  2772.                                  calls.  When this option is disabled, it 
  2773.                                  causes out-of-band data to be placed in the 
  2774.                                  priority data input queue as it is received, 
  2775.                                  making it available to recv(), and recvfrom(), 
  2776.                                  only by specifying the MSG_OOB flag in those 
  2777.                                  calls. 
  2778.  
  2779.       SO_RCVBUF                  Retrieves buffer size for input. This value 
  2780.                                  tailors the receive buffer size for specific 
  2781.                                  application needs, such as increasing the 
  2782.                                  buffer size for high-volume connections. 
  2783.  
  2784.       SO_RCVLOWAT                Retrieves receive low-water mark that controls 
  2785.                                  when a recv() call returns when less data is 
  2786.                                  available than the recv() call is requesting. 
  2787.                                  If at least SO_RCVLOWAT bytes are available, 
  2788.                                  then the recv() call returns those bytes.  The 
  2789.                                  default is 1 for both stream and datagram 
  2790.                                  sockets. 
  2791.  
  2792.       SO_RCVTIMEO                Retrieves receive timeout information. This 
  2793.                                  value limits the length of a blocking receive 
  2794.                                  call.  This value is ignored for non-blocking 
  2795.                                  calls. 
  2796.  
  2797.       SO_REUSEADDR               (stream and datagram sockets only) Retrieves 
  2798.                                  the current ability of the socket to reuse 
  2799.                                  local addresses. When enabled, this option 
  2800.                                  allows local addresses that are already in use 
  2801.                                  to be bound. This alters the normal algorithm 
  2802.                                  used in the bind() call. At connect time, 
  2803.                                  Network Services checks to be sure that no 
  2804.                                  local address and port have the same foreign 
  2805.                                  address and port. The error SOCEADDRINUSE is 
  2806.                                  returned if the association already exists. 
  2807.  
  2808.       SO_REUSEPORT               Retrieves the current ability of the socket to 
  2809.                                  reuse a local address and local port. 
  2810.  
  2811.       SO_SNDBUF                  Retrieves the size of the send buffer. This 
  2812.                                  value tailors the send buffer size for 
  2813.                                  specific application needs, such as increasing 
  2814.                                  the buffer size for high-volume connections. 
  2815.  
  2816.       SO_SNDLOWAT                Retrieves send low-water mark that influences 
  2817.                                  socket flow control operations.  SO_SNDLOWAT 
  2818.                                  is used for stream sockets, but not datagram 
  2819.                                  sockets.  During a send operation, if the 
  2820.                                  socket code must wait for space to be 
  2821.                                  available in the send buffer before sending 
  2822.                                  data, the socket waits for at least 
  2823.                                  SO_SNDLOWAT bytes to be available in the send 
  2824.                                  buffer before sending the data.  The default 
  2825.                                  value is the size of a cluster mbuf. 
  2826.  
  2827.       SO_SNDTIMEO                Retrieves send timeout information. This value 
  2828.                                  limits the length of a blocking send call. 
  2829.                                  This value is ignored for non-blocking calls. 
  2830.  
  2831.       SO_TYPE                    Returns the type of the socket.  On return, 
  2832.                                  the integer pointed to by optval is set to one 
  2833.                                  of the following: SOCK_STREAM, SOCK_SEQPACKET, 
  2834.                                  SOCK_DGRAM, or SOCK_RAW. 
  2835.  
  2836.  struct linger: For the SO_LINGER option, optval points to a linger structure. 
  2837.  This structure is defined in the <SYS\SOCKET.H> file and contains the 
  2838.  following fields: 
  2839.  
  2840.  
  2841.            Field          Description 
  2842.  
  2843.       l_onoff             Option on/off 
  2844.  
  2845.       l_linger            Linger time 
  2846.  
  2847.  The l_onoff field is set to zero if the SO_LINGER option is being disabled. A 
  2848.  nonzero value enables the option. 
  2849.  
  2850.  The l_linger field specifies the amount of time in seconds to linger on close. 
  2851.  A value of zero causes an abnormal close.  TCP discards any data still queued 
  2852.  to be sent on the connection and sends a reset to the peer.  The peer sees 
  2853.  this as an abnormal close when it gets an error on an outstanding receive. 
  2854.  
  2855.  struct timeval: For the SO_RCVTIMEO and SO_SNDTIMEO options, optval points to 
  2856.  a timeval structure.  This structure is defined in the <SYS\TIME.H> file and 
  2857.  contains the following fields: 
  2858.  
  2859.  
  2860.            Field          Description 
  2861.  
  2862.       tv_sec              Number of seconds 
  2863.  
  2864.       tv_usec             Number of microseconds 
  2865.  
  2866.  For the internet domain, the finest resolution is milliseconds, thus the 
  2867.  tv_usec field is converted. In this conversion, anything less than a 
  2868.  millisecond is truncated.  For example, if you call setsockopt() to set 
  2869.  tv_usec to 31, the next getsockopt() call returns a 0 for tv_usec.  If you 
  2870.  call setsockopt() to set tv_usec to 1031, the next getsockopt() returns 1000. 
  2871.  
  2872.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  2873.   Γöé Table 12. Supported getsockopt() Socket Options for IPPROTO_IP     Γöé
  2874.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2875.   Γöé            Γöé                 Γöé    Γöé BOOLEANΓöé
  2876.   Γöé            Γöé                 Γöé DATA  Γöé OR   Γöé
  2877.   Γöé OPTION NAME      Γöé DESCRIPTION           Γöé TYPE  Γöé VALUE  Γöé
  2878.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2879.   Γöé IP_MULTICAST_IF    Γöé provides the default interface Γöé structΓöé value  Γöé
  2880.   Γöé            Γöé for outgoing multicasts     Γöé in_addΓöé     Γöé
  2881.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2882.   Γöé IP_MULTICAST_LOOP   Γöé causes a loopback of outgoing  Γöé uchar Γöé booleanΓöé
  2883.   Γöé            Γöé multicast            Γöé    Γöé     Γöé
  2884.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2885.   Γöé IP_MULTICAST_TTL   Γöé provides default TTL for out-  Γöé uchar Γöé value  Γöé
  2886.   Γöé            Γöé going multicast         Γöé    Γöé     Γöé
  2887.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2888.   Γöé IP_OPTIONS      Γöé provides options in IP header  Γöé void  Γöé value  Γöé
  2889.   Γöé            Γöé to be included in outgoing   Γöé *   Γöé     Γöé
  2890.   Γöé            Γöé datagrams            Γöé    Γöé     Γöé
  2891.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2892.   Γöé IP_RECVDSTADDR    Γöé allows queueing of IP destina- Γöé int  Γöé booleanΓöé
  2893.   Γöé            Γöé tion address          Γöé    Γöé     Γöé
  2894.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2895.   Γöé IP_TOS        Γöé gives type of service for out- Γöé int  Γöé booleanΓöé
  2896.   Γöé            Γöé going datagrams         Γöé    Γöé     Γöé
  2897.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2898.   Γöé IP_TTL        Γöé gives time to live for out-   Γöé int  Γöé value  Γöé
  2899.   Γöé            Γöé going datagrams         Γöé    Γöé     Γöé
  2900.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  2901.  
  2902.  The following options are recognized for option level IPPROTO_IP and are 
  2903.  supported for the internet communication domain only. 
  2904.  
  2905.  
  2906.            Option                Description 
  2907.  
  2908.       IP_MULTICAST_IF            Retrieves the default interface for outgoing 
  2909.                                  multicasts. Normally this is the interface 
  2910.                                  selected for an outgoing interface based on 
  2911.                                  the destination.  This default can be 
  2912.                                  overridden by specifying the IP address of the 
  2913.                                  outgoing interface. 
  2914.  
  2915.       IP_MULTICAST_LOOP          Retrieves the value of the loopback setting 
  2916.                                  for outgoing multicasts. If this value is 0, 
  2917.                                  packets are not looped back and delivered to 
  2918.                                  the transmitting interface, even if the 
  2919.                                  interface is a member of the multicasting 
  2920.                                  group. If this value is 1, packets are looped 
  2921.                                  back if the interface is a member of the 
  2922.                                  multicasting group.  The default value is 1. 
  2923.  
  2924.       IP_MULTICAST_TTL           Retrieves the default TTL for outgoing 
  2925.                                  multicasts. The default is 1, which causes 
  2926.                                  multicast datagrams to remain on the local 
  2927.                                  network. This value is also used by multicast 
  2928.                                  routers to have a threshold policy to drop 
  2929.                                  multicast packets. Packets can be dropped by a 
  2930.                                  router even though its TTL is not 0. 
  2931.  
  2932.       IP_OPTIONS                 Retrieves the options in the IP header that 
  2933.                                  are included in outgoing datagrams. 
  2934.  
  2935.       IP_RECVDSTADDR             (datagram sockets only) Retrieves if IP 
  2936.                                  destination address is passed on the recvmsg() 
  2937.                                  call is enabled or disabled. The IP 
  2938.                                  destination is passed pack in the msg_control 
  2939.                                  parameter, if the msg_controllen parameter is 
  2940.                                  less than 4 bytes, the flags indicate the 
  2941.                                  control information was truncated. 
  2942.  
  2943.       IP_TOS                     Retrieves the type of service (TOS) used in 
  2944.                                  outgoing datagram and stream packets. 
  2945.  
  2946.       IP_TTL                     Retrieves the time to live (TTL) for outgoing 
  2947.                                  unicast packets. A TTL value of 1 prevents 
  2948.                                  packets from being routed to other networks. 
  2949.                                  Raw sockets default to the maximum of 255, 
  2950.                                  datagram and stream sockets default to 64. 
  2951.  
  2952.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  2953.   Γöé Table 13. Supported getsockopt() Socket Options for IPPROTO_TCP     Γöé
  2954.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2955.   Γöé            Γöé                 Γöé    Γöé BOOLEANΓöé
  2956.   Γöé            Γöé                 Γöé DATA  Γöé OR   Γöé
  2957.   Γöé OPTION NAME      Γöé DESCRIPTION           Γöé TYPE  Γöé VALUE  Γöé
  2958.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2959.   Γöé TCP_MAXSEG      Γöé gets TCP maximum segment size  Γöé int  Γöé value  Γöé
  2960.   Γöé            Γöé after a connection is estab-  Γöé    Γöé     Γöé
  2961.   Γöé            Γöé lished             Γöé    Γöé     Γöé
  2962.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2963.   Γöé TCP_NODELAY      Γöé indicates that the send to   Γöé int  Γöé booleanΓöé
  2964.   Γöé            Γöé coalesce packets should not be Γöé    Γöé     Γöé
  2965.   Γöé            Γöé delayed             Γöé    Γöé     Γöé
  2966.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  2967.  
  2968.  The following options are recognized for option level IPPROTO_TCP and are 
  2969.  supported for the internet communication domain only. 
  2970.  
  2971.  
  2972.            Option                Description 
  2973.  
  2974.       TCP_MAXSEG                 Retrieves the TCP maximum segment size after a 
  2975.                                  connection is established. 
  2976.  
  2977.       TCP_NODELAY                (stream sockets only) Retrieves the current 
  2978.                                  ability of the socket to disable the small 
  2979.                                  packet avoidance algorithm so that the 
  2980.                                  client's TCP sends small packets as soon as 
  2981.                                  possible. This option may provide a 
  2982.                                  performance improvement for some applications 
  2983.                                  on a LAN, but can degrade performance on Wide 
  2984.                                  Area Networks (WAN). 
  2985.  
  2986.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  2987.   Γöé Table 14. Supported getsockopt() Socket Options for NBPROTO_NB     Γöé
  2988.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2989.   Γöé            Γöé                 Γöé    Γöé BOOLEANΓöé
  2990.   Γöé            Γöé                 Γöé DATA  Γöé OR   Γöé
  2991.   Γöé OPTION NAME      Γöé DESCRIPTION           Γöé TYPE  Γöé VALUE  Γöé
  2992.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2993.   Γöé NB_DGRAM_TYPE     Γöé type of datagrams to receive  Γöé int  Γöé value  Γöé
  2994.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  2995.  
  2996.  The following option is recognized for option level NBPROTO_NBP and is 
  2997.  supported for the NetBIOS communication domain only. 
  2998.            Option                Description 
  2999.  
  3000.       NB_DGRAM_TYPE              (datagram sockets only) Gets type of datagrams 
  3001.                                  to be received on the socket.  The possible 
  3002.                                  values are: 
  3003.  
  3004.                                       NB_DGRAM               The socket is to 
  3005.                                                              receive normal 
  3006.                                                              (unicast) 
  3007.                                                              datagrams only. 
  3008.                                       NB_BROADCAST           The socket is to 
  3009.                                                              receive broadcast 
  3010.                                                              datagrams only. 
  3011.                                       NB_DGRAM_ANY           The socket can 
  3012.                                                              receive both 
  3013.                                                              normal or 
  3014.                                                              broadcast 
  3015.                                                              datagrams. 
  3016.  
  3017.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  3018.  return value -1 indicates an error. You can get the specific error code by 
  3019.  calling sock_errno() or psock_errno(). 
  3020.  
  3021.  
  3022.            sock_errno() Value    Description 
  3023.  
  3024.       SOCECOMMSYS                Internal communications error.  Contact IBM 
  3025.                                  Service. 
  3026.  
  3027.       SOCEFAULT                  Using optval and optlen parameters results in 
  3028.                                  an attempt to access memory outside the caller 
  3029.                                  address space. 
  3030.  
  3031.       SOCEINVAL                  The level parameter is not recognized. 
  3032.  
  3033.       SOCENOPROTOOPT             The optname parameter is not recognized. 
  3034.  
  3035.       SOCENOTSOCK                The s parameter is not a valid socket 
  3036.                                  descriptor. 
  3037.  
  3038.  Examples:  The following are examples of the getsockopt() call. See 
  3039.  setsockopt() for examples of how setsockopt() sets the socket options. 
  3040.  
  3041.   int rc;
  3042.   int s;
  3043.   int optval;
  3044.   int optlen;
  3045.   struct linger lstruct;
  3046.   int getsockopt(int s, int level, int optname, char *optval, int *optlen);
  3047.   /* extracted from sys\socket.h */
  3048.   .
  3049.   .
  3050.   .
  3051.   /* Is out of band data in the normal input queue? */
  3052.   optlen = sizeof(int);
  3053.   rc = getsockopt( s, SOL_SOCKET, SO_OOBINLINE, (char *) &optval, &optlen);
  3054.   if (rc == 0)
  3055.   {
  3056.       if (optlen == sizeof(int))
  3057.       {
  3058.            if (optval)
  3059.               /* yes it is in the normal queue */
  3060.            else
  3061.               /* no it is not                  */
  3062.       }
  3063.   }
  3064.  
  3065.   .
  3066.   .
  3067.   .
  3068.   /* Do I linger on close? */
  3069.   optlen = sizeof(lstruct);
  3070.   rc = getsockopt( s, SOL_SOCKET, SO_LINGER, (char *) &lstruct, &optlen);
  3071.   if (rc == 0)
  3072.   {
  3073.       if (optlen == sizeof(lstruct))
  3074.       {
  3075.            if (lstruct.l_onoff)
  3076.               /* yes I linger */
  3077.            else
  3078.               /* no I do not  */
  3079.       }
  3080.   }
  3081.  
  3082.  
  3083. ΓòÉΓòÉΓòÉ 6.7. ioctl() ΓòÉΓòÉΓòÉ
  3084.  
  3085. Performs special operations on socket. 
  3086.  
  3087. #include <types.h>
  3088. #include <sys\socket.h>
  3089. #include <sys\ioctl.h>
  3090. #include <net\route.h>
  3091. #include <net\if.h>
  3092. #include <net\if_arp.h>
  3093.  
  3094. int ioctl(s, cmd, data, lendata)
  3095. int s;
  3096. int cmd;
  3097. caddr_t data;
  3098. int lendata;
  3099.  
  3100.  Parameter      Description 
  3101.  
  3102.  s              Socket descriptor 
  3103.  
  3104.  cmd            Command to perform 
  3105.  
  3106.  data           Pointer to the data associated with cmd 
  3107.  
  3108.  lendata        Length of the data in bytes 
  3109.  
  3110.  Description:  This call controls the operating characteristics of sockets. The 
  3111.  data parameter is a pointer to data associated with the particular command, 
  3112.  and its format depends on the command that is requested. 
  3113.  
  3114.  Internet: The following ioctl commands are supported for the internet domain: 
  3115.  
  3116.  
  3117.            Command              Description 
  3118.  
  3119.       FIOASYNC                  This command has no affect. 
  3120.  
  3121.       FIONBIO                   Sets or clears nonblocking input/output for a 
  3122.                                 socket. When this option is set, input/output 
  3123.                                 calls do not block until the call is completed. 
  3124.                                 The data parameter is a pointer to an integer. 
  3125.                                 If the integer is 0, nonblocking input/output 
  3126.                                 on the socket is cleared. Otherwise, the socket 
  3127.                                 is set for nonblocking input/output. 
  3128.  
  3129.       FIONREAD                  Gets the number of immediately readable bytes 
  3130.                                 for the socket, and returns this value in an 
  3131.                                 integer pointed to by the data parameter. 
  3132.  
  3133.       SIOCATMARK                Queries whether the current location in the 
  3134.                                 data input is pointing to out-of-band data, and 
  3135.                                 returns this value in an integer pointed to by 
  3136.                                 the data parameter. An integer value of 1 
  3137.                                 indicates the socket points to a mark in the 
  3138.                                 data stream for out-of-band data.  Otherwise, 
  3139.                                 the integer value is 0. 
  3140.  
  3141.       SIOCGIFADDR               Gets the network interface address, and returns 
  3142.                                 this value in an ifreq structure pointed to by 
  3143.                                 the data parameter. 
  3144.  
  3145.       SIOCGIFBRDADDR            Gets the network interface broadcast address, 
  3146.                                 and returns this value in an ifreq structure 
  3147.                                 pointed to by the data parameter. 
  3148.  
  3149.       SIOCGIFCONF               Gets the network interface configuration, and 
  3150.                                 returns this value in an ifconf structure 
  3151.                                 pointed to by the data parameter. 
  3152.  
  3153.       SIOCGIFDSTADDR            (stream sockets only) Gets the network 
  3154.                                 interface destination address, and returns this 
  3155.                                 value in an ifreq structure pointed to by the 
  3156.                                 data parameter. 
  3157.  
  3158.       SIOCGIFFLAGS              Gets the network interface flags, and returns 
  3159.                                 these values in an ifreq structure pointed to 
  3160.                                 by the data parameter. 
  3161.  
  3162.       SIOCGIFMETRIC             (stream sockets only) Gets the network 
  3163.                                 interface routing metric, and returns this 
  3164.                                 value in an ifreq structure pointed to by the 
  3165.                                 data parameter. 
  3166.  
  3167.       SIOCGIFNETMASK            Gets the network interface network mask, and 
  3168.                                 returns this value in an ifreq structure 
  3169.                                 pointed to by the data parameter. 
  3170.  
  3171.       SIOCSIFADDR               (stream sockets only) Sets the network 
  3172.                                 interface address to the value passed in an 
  3173.                                 ifreq structure pointed to by the data 
  3174.                                 parameter. 
  3175.  
  3176.       SIOCSIFBRDADDR            (stream sockets only) Sets the network 
  3177.                                 interface broadcast address to the value passed 
  3178.                                 in an ifreq structure pointed to by the data 
  3179.                                 parameter. 
  3180.  
  3181.       SIOCSIFDSTADDR            (stream sockets only) Sets the network 
  3182.                                 interface destination address to the value 
  3183.                                 passed in an ifreq structure pointed to by the 
  3184.                                 data parameter. 
  3185.  
  3186.  NetBIOS: The following ioctl commands are supported for the NetBIOS domain: 
  3187.  
  3188.  
  3189.            Command              Description 
  3190.  
  3191.       FIONBIO                   Sets or clears nonblocking input/output for a 
  3192.                                 socket. When this option is set, input/output 
  3193.                                 calls do not block until the call is completed. 
  3194.                                 The data parameter is a pointer to an integer. 
  3195.                                 If the integer is 0, nonblocking input/output 
  3196.                                 on the socket is cleared. Otherwise, the socket 
  3197.                                 is set for nonblocking input/output. 
  3198.  
  3199.  Local IPC: The following ioctl commands are supported for the Local IPC 
  3200.  domain: 
  3201.  
  3202.  
  3203.            Command              Description 
  3204.  
  3205.       FIONBIO                   Sets or clears nonblocking input/output for a 
  3206.                                 socket. When this option is set, input/output 
  3207.                                 calls do not block until the call is completed. 
  3208.                                 The data parameter is a pointer to an integer. 
  3209.                                 If the integer is 0, nonblocking input/output 
  3210.                                 on the socket is cleared. Otherwise, the socket 
  3211.                                 is set for nonblocking input/output. 
  3212.  
  3213.  struct ifreq: The ifreq structure is defined in the <NET\IF.H> header file. 
  3214.  
  3215.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  3216.  return value -1 indicates an error. You can get the specific error code by 
  3217.  calling sock_errno() or psock_errno(). 
  3218.  
  3219.  
  3220.            sock_errno() Value   Description 
  3221.  
  3222.       SOCECOMMSYS               Internal communications error.  Contact IBM 
  3223.                                 Service. 
  3224.  
  3225.       SOCEFAULT                 Using data and lendata results in an attempt to 
  3226.                                 access memory outside the caller address space. 
  3227.  
  3228.       SOCEINVAL                 The request is not valid or not supported. 
  3229.  
  3230.       SOCENOTSOCK               The s parameter is not a valid socket 
  3231.                                 descriptor. 
  3232.  
  3233.       SOCENXIO                  No such device or address.  Possibly trying to 
  3234.                                 get interface information on the wrong device. 
  3235.  
  3236.       SOCEOPNOTSUPP             The operation is not supported on the socket. 
  3237.  
  3238.  Example:  The following is an example of the ioctl() call. 
  3239.  
  3240.   int s;
  3241.   int dontblock;
  3242.   int rc;
  3243.   int ioctl(int s, int cmd, caddr_t data, int lendata);  /* extracted from sys\socket.h */
  3244.   .
  3245.   .
  3246.   .
  3247.   /* Place the socket into nonblocking mode */
  3248.   dontblock = 1;
  3249.   rc = ioctl(s, FIONBIO, (char *) &dontblock, sizeof(dontblock));
  3250.   .
  3251.   .
  3252.   .
  3253.  
  3254.  
  3255. ΓòÉΓòÉΓòÉ 6.8. listen() ΓòÉΓòÉΓòÉ
  3256.  
  3257. Completes the binding necessary for a socket to accept connections and creates 
  3258. a connection request queue for incoming requests. 
  3259.  
  3260. #include <types.h>
  3261. #include <sys\socket.h>
  3262.  
  3263. int listen(s, backlog)
  3264. int s;
  3265. int backlog;
  3266.  
  3267.  Parameter      Description 
  3268.  
  3269.  s              Socket descriptor. 
  3270.  
  3271.  backlog        Specifies the maximum limit of pending connections that can be 
  3272.                 queued on this socket. 
  3273.  
  3274.  Description: 
  3275.  
  3276.  The listen() call performs two tasks: completes the binding necessary for a 
  3277.  socket s, if bind() has not been called for s and creates a connection request 
  3278.  queue of length backlog to queue incoming connection requests. When the queue 
  3279.  is full, additional connection requests are ignored. 
  3280.  
  3281.  The listen() call indicates a readiness to accept client connection requests. 
  3282.  It transforms an active socket into a passive socket.  After listen() is 
  3283.  called, s can never be used as an active socket to initiate connection 
  3284.  requests. Listen() is called after allocating a socket with socket() and after 
  3285.  binding a name to s with bind().  Listen() must be called before calling 
  3286.  ACCEPT(). 
  3287.  
  3288.  Listen() can be called on stream and sequenced packet sockets only. 
  3289.  
  3290.  If the backlog parameter is less than 0, listen() interprets backlog as 0. If 
  3291.  the backlog parameter is greater than SOMAXCONN, as defined in the 
  3292.  <SYS\SOCKET.H> header file, listen() interprets backlog as SOMAXCONN. 
  3293.  
  3294.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  3295.  return value -1 indicates an error. You can get the specific error code by 
  3296.  calling sock_errno() or psock_errno(). 
  3297.  
  3298.  
  3299.            sock_errno() Value   Description 
  3300.  
  3301.       SOCECOMMSYS               Internal communications error.  Contact IBM 
  3302.                                 Service. 
  3303.  
  3304.       SOCENOTSOCK               The s parameter is not a valid socket 
  3305.                                 descriptor. 
  3306.  
  3307.       SOCEOPNOTSUPP             The s parameter is not a socket descriptor that 
  3308.                                 supports the listen() call. 
  3309.  
  3310.  
  3311. ΓòÉΓòÉΓòÉ 6.9. psock_errno() ΓòÉΓòÉΓòÉ
  3312.  
  3313. Writes a short error message to the standard error device. 
  3314.  
  3315. #include <nerrno.h>
  3316.  
  3317.  
  3318. void psock_errno(s)
  3319. char *s;
  3320.  
  3321.  Parameter      Description 
  3322.  
  3323.  s              Pointer to a buffer 
  3324.  
  3325.  Description:  This call writes a short error message to the standard error 
  3326.  display describing the last error encountered during a call to a socket 
  3327.  library function on this thread. If s is not a NULL pointer and does not point 
  3328.  to a null string, the string it points to is printed, followed by a colon, 
  3329.  followed by a space, followed by the message.  If s is a NULL pointer or 
  3330.  points to a null string, only the message is printed. 
  3331.  
  3332.  You can get the specific error code by calling sock_errno().  The error code 
  3333.  is set when errors occur.  Subsequent socket calls do not clear the error 
  3334.  code. 
  3335.  
  3336.  
  3337. ΓòÉΓòÉΓòÉ 6.10. readv() ΓòÉΓòÉΓòÉ
  3338.  
  3339. Receives data on a socket into a set of buffers. 
  3340.  
  3341. #include <types.h>
  3342. #include <sys\socket.h>
  3343.  
  3344. int readv(s, iov, iovcnt)
  3345. int s;
  3346. struct iovec *iov;
  3347. int iovcnt;
  3348.  
  3349.  Parameter      Description 
  3350.  
  3351.  s              Socket descriptor. 
  3352.  
  3353.  iov            Pointer to an array of iovec structures. 
  3354.  
  3355.  iovcnt         Number of iovec structures pointed to by the iov parameter. The 
  3356.                 maximum number of iovec structures is 32. 
  3357.  
  3358.  Description:  This call reads data on a socket with descriptor s and stores it 
  3359.  in a set of buffers. The data is scattered into the buffers specified by 
  3360.  iov[0]...iov[iovcnt-1]. The iovec structure is defined in the <SYS\SOCKET.H> 
  3361.  header file and contains the following fields: 
  3362.  
  3363.  
  3364.            Field          Description 
  3365.  
  3366.       iov_base            Points to the buffer 
  3367.  
  3368.       iov_len             Length of the buffer 
  3369.  
  3370.  The readv() call applies to connected sockets only. For information on how to 
  3371.  use readv() with datagram and raw sockets, see "Datagram or raw sockets".. 
  3372.  
  3373.  This call returns up to the number of bytes in the buffers pointed to by the 
  3374.  iov parameter.  This number is the sum of all iov_len fields. If less than the 
  3375.  number of bytes requested is available, the call returns the number currently 
  3376.  available. If data is not available at the socket with descriptor s, the 
  3377.  readv() call waits for data to arrive and blocks the caller, unless the socket 
  3378.  is in nonblocking mode. See ioctl() for a description of how to set 
  3379.  nonblocking mode. 
  3380.  
  3381.  Return and sock_errno() Values: If successful, the return value is the number 
  3382.  of bytes read into the buffers. The return value -1 indicates an error. You 
  3383.  can get the specific error code by calling sock_errno() or psock_errno(). 
  3384.  
  3385.  
  3386.            sock_errno() Value    Description 
  3387.  
  3388.       SOCECOMMSYS                Internal communications error.  Contact IBM 
  3389.                                  Service. 
  3390.  
  3391.       SOCEFAULT                  Using iov and iovcnt results in an attempt to 
  3392.                                  access memory outside the caller address 
  3393.                                  space. 
  3394.  
  3395.       SOCEINVAL                  iovcnt was not valid, or one of the fields in 
  3396.                                  the iov array was not valid. 
  3397.  
  3398.       SOCENOTSOCK                The s parameter is not a valid socket 
  3399.                                  descriptor. 
  3400.  
  3401.       SOCEWOULDBLOCK             The s parameter is in nonblocking mode and no 
  3402.                                  data is available to read, OR the SO_RCVTIMEO 
  3403.                                  option has been set for socket s and the 
  3404.                                  timeout expired before any data arrived to 
  3405.                                  read. 
  3406.  
  3407.  
  3408. ΓòÉΓòÉΓòÉ 6.11. recv() ΓòÉΓòÉΓòÉ
  3409.  
  3410. Receives data on a connected socket. 
  3411.  
  3412. #include <types.h>
  3413. #include <sys\socket.h>
  3414.  
  3415. int recv(s, buf, len, flags)
  3416. int s;
  3417. char *buf;
  3418. int len;
  3419. int flags;
  3420.  
  3421.  Parameter      Description 
  3422.  
  3423.  s              Socket descriptor. 
  3424.  
  3425.  buf            Pointer to the buffer that receives the data. 
  3426.  
  3427.  len            Length of the buffer in bytes pointed to by the buf parameter. 
  3428.  
  3429.  flags          Set by specifying one or more of the following flags. If you 
  3430.                 specify more than one flag, use the logical OR operator (|) to 
  3431.                 separate them. Setting this parameter is supported for sockets 
  3432.                 in the internet domain only. 
  3433.  
  3434.                 MSG_OOB           Reads any out-of-band data on the socket. 
  3435.  
  3436.                 MSG_PEEK          Peeks at the data present on the socket; the 
  3437.                                   data is returned but not consumed, so that a 
  3438.                                   subsequent receive operation returns the same 
  3439.                                   data. 
  3440.  
  3441.  Description:  This call receives data on a socket with descriptor s and stores 
  3442.  it in the buffer pointed to by buf. The recv() call applies to connected 
  3443.  sockets only. For information on how to use recv() with datagram and raw 
  3444.  sockets, see "Datagram or raw sockets".. 
  3445.  
  3446.  The recv() call returns the length of the incoming data. If a datagram is too 
  3447.  long to fit in the buffer, the excess is discarded.  No data is discarded for 
  3448.  stream sockets. If data is not available at the socket with descriptor s, the 
  3449.  recv() call waits for a message to arrive and blocks the caller, unless the 
  3450.  socket is in nonblocking mode. See ioctl() for a description of how to set 
  3451.  nonblocking mode. 
  3452.  
  3453.  Return and sock_errno() Values:  If successful, the return value is the length 
  3454.  of the data, in bytes.  The return value 0 indicates that the connection is 
  3455.  closed. The return value -1 indicates an error. You can get the specific error 
  3456.  code by calling sock_errno() or psock_errno(). 
  3457.  
  3458.  
  3459.            sock_errno() Value   Description 
  3460.  
  3461.       SOCECOMMSYS               Internal communications error.  Contact IBM 
  3462.                                 Service. 
  3463.  
  3464.       SOCEFAULT                 Using the buf and len parameters results in an 
  3465.                                 attempt to access memory outside the caller 
  3466.                                 address space. 
  3467.  
  3468.       SOCEINVAL                 One of the parameters has an invalid value. 
  3469.  
  3470.       SOCENOTCONN               The socket is not connected. 
  3471.  
  3472.       SOCENOTSOCK               The s parameter is not a valid socket 
  3473.                                 descriptor. 
  3474.  
  3475.       SOCEWOULDBLOCK            The s parameter is in nonblocking mode and no 
  3476.                                 data is available to receive, or the 
  3477.                                 SO_RCVTIMEO option has been set for socket s 
  3478.                                 and the timeout expired before any data arrived 
  3479.                                 to receive. 
  3480.  
  3481.  
  3482. ΓòÉΓòÉΓòÉ 6.12. recvfrom() ΓòÉΓòÉΓòÉ
  3483.  
  3484. Receives data on a socket. 
  3485.  
  3486. #include <types.h>
  3487. #include <sys\socket.h>
  3488.  
  3489. int recvfrom(s, buf, len, flags, name, namelen)
  3490. int s;
  3491. char *buf;
  3492. int len;
  3493. int flags;
  3494. struct sockaddr *name;
  3495. int *namelen;
  3496.  
  3497.  Parameter      Description 
  3498.  
  3499.  s              Socket descriptor. 
  3500.  
  3501.  buf            Pointer to the buffer that receives the data. 
  3502.  
  3503.  len            Length of the buffer in bytes pointed to by the buf parameter. 
  3504.  
  3505.  flags          Set by specifying one or more of the following flags. If you 
  3506.                 specify more than one flag, use the logical OR operator (|) to 
  3507.                 separate them. Setting this parameter is supported for sockets 
  3508.                 in the internet domain only. 
  3509.  
  3510.                 MSG_OOB             Reads any out-of-band data on the socket. 
  3511.  
  3512.                 MSG_PEEK            Peeks at the data present on the socket; 
  3513.                                     the data is returned but not consumed, so 
  3514.                                     that a subsequent receive operation returns 
  3515.                                     the same data. 
  3516.  
  3517.  name           Pointer to a sockaddr structure (buffer) containing the source 
  3518.                 address of the data. If name is a nonzero value, the source 
  3519.                 address is returned. 
  3520.  
  3521.  namelen        Pointer to the size in bytes of the buffer pointed to by name. 
  3522.  
  3523.  Description:  The recvfrom() call receives data on a socket with descriptor s 
  3524.  and stores it in a buffer. The recvfrom() call applies to any socket type, 
  3525.  whether connected or not. 
  3526.  
  3527.  If name is nonzero, the address of the data sender is returned. The namelen 
  3528.  parameter is first initialized to the size of the buffer associated with name; 
  3529.  on return, it is modified to indicate the actual number of bytes stored there. 
  3530.  
  3531.  The recvfrom() call returns the length of the incoming message or data. If a 
  3532.  datagram is too long to fit in the supplied buffer, the excess is discarded. 
  3533.  No data is discarded for stream sockets. If data is not available at the 
  3534.  socket with descriptor s, the recvfrom() call waits for a message to arrive 
  3535.  and blocks the caller, unless the socket is in nonblocking mode.  See ioctl() 
  3536.  for a description of how to set nonblocking mode. 
  3537.  
  3538.  Return and sock_errno() Values:  If successful, the return value is the length 
  3539.  of the data, in bytes. The return value -1 indicates an error. You can get the 
  3540.  specific error code by calling sock_errno() or psock_errno(). 
  3541.  
  3542.  
  3543.            sock_errno() Value    Description 
  3544.  
  3545.       SOCECOMMSYS                Internal communications error.  Contact IBM 
  3546.                                  Service. 
  3547.  
  3548.       SOCEFAULT                  Using the buf and len parameters results in an 
  3549.                                  attempt to access memory outside the caller 
  3550.                                  address space. 
  3551.  
  3552.       SOCEINVAL                  One of the parameters has an invalid value. 
  3553.  
  3554.       SOCENOTCONN                The socket is not connected. 
  3555.  
  3556.       SOCENOTSOCK                The s parameter is not a valid socket 
  3557.                                  descriptor. 
  3558.  
  3559.       SOCEWOULDBLOCK             The s parameter is in nonblocking mode and no 
  3560.                                  data is available to receive, or the 
  3561.                                  SO_RCVTIMEO option has been set for socket s 
  3562.                                  and the timeout expired before any data 
  3563.                                  arrived to receive. 
  3564.  
  3565.  
  3566. ΓòÉΓòÉΓòÉ 6.13. recvmsg() ΓòÉΓòÉΓòÉ
  3567.  
  3568. Receives data and control information on a specified socket. 
  3569.  
  3570. #include <types.h>
  3571. #include <sys\socket.h>
  3572.  
  3573. int recvmsg(s, msg, flags)
  3574. int s;
  3575. struct msghdr *msg;
  3576. int flags;
  3577.  
  3578.  Parameter      Description 
  3579.  
  3580.  s              Socket descriptor. 
  3581.  
  3582.  msg            Pointer to a message header that receives the message. 
  3583.  
  3584.  flags          Set by specifying one or more of the following flags. If you 
  3585.                 specify more than one flag, use the logical OR operator (|) to 
  3586.                 separate them. Setting this parameter is supported for sockets 
  3587.                 in the internet domain only. 
  3588.  
  3589.                 MSG_OOB           Reads any out-of-band data on the socket. 
  3590.  
  3591.                 MSG_PEEK          Peeks at the data present on the socket; the 
  3592.                                   data is returned, but not consumed, so that a 
  3593.                                   subsequent receive operation returns the same 
  3594.                                   data. 
  3595.  
  3596.  Description:  This call receives a message on a socket with descriptor s. 
  3597.  
  3598.  Parameter            Description 
  3599.  
  3600.  msg_name             The optional pointer to the buffer containing the 
  3601.                       recipient address 
  3602.  
  3603.  msg_namelen          The size of the address buffer 
  3604.  
  3605.  msg_iov              An array of iovec buffers containing the message 
  3606.  
  3607.  msg_iovlen           The number of elements in the msg_iov array 
  3608.  
  3609.  msg_accreights       The access rights recived.  This field is ignored. 
  3610.  
  3611.  msg_accrightslen     The length of the access right received.  This field is 
  3612.                       ignored. 
  3613.  
  3614.  The recvmsg() call applies to connection-oriented or connectionless sockets. 
  3615.  
  3616.  This call returns the length of the data received. If a datagram is too long 
  3617.  to fit in the supplied buffer, the excess is discarded.  No data is discarded 
  3618.  for stream sockets. If data is not available at the socket with descriptor s, 
  3619.  the recvmsg() call waits for a message to arrive and blocks the caller, unless 
  3620.  the socket is in nonblocking mode. See ioctl() for a description of how to set 
  3621.  nonblocking mode. 
  3622.  
  3623.  Return and sock_errno() Values:  If successful, the return value is the length 
  3624.  of the message, in bytes. The return value 0 indicates the connection is 
  3625.  closed; the return value -1 indicates an error. You can get the specific error 
  3626.  code by calling sock_errno() or psock_errno(). 
  3627.  
  3628.  
  3629.            sock_errno() Value   Description 
  3630.  
  3631.       SOCECOMMSYS               Internal communications error.  Contact IBM 
  3632.                                 Service. 
  3633.  
  3634.       SOCEFAULT                 Using msg results in an attempt to access 
  3635.                                 memory outside the caller address space. 
  3636.  
  3637.       SOCENOTCONN               The socket is not connected. 
  3638.  
  3639.       SOCENOTSOCK               The s parameter is not a valid socket 
  3640.                                 descriptor. 
  3641.  
  3642.       SOCEWOULDBLOCK            The s parameter is in nonblocking mode, and no 
  3643.                                 data is available to receive, or the 
  3644.                                 SO_RCVTIMEO option has been set for socket s 
  3645.                                 and the timeout expired before any data arrived 
  3646.                                 to receive. 
  3647.  
  3648.  
  3649. ΓòÉΓòÉΓòÉ 6.14. select() ΓòÉΓòÉΓòÉ
  3650.  
  3651. Gets read, write, and exception status on a group of sockets. 
  3652.  
  3653. Network Services supports two versions of the select() call: 
  3654.  
  3655.      OS/2 Version 
  3656.      Berkeley Software Distributions (BSD) Version 
  3657.  
  3658.  Either version of select() can be used. The OS/2 version has better 
  3659.  performance. However, the BSD version is more portable. 
  3660.  
  3661.  
  3662. ΓòÉΓòÉΓòÉ 6.14.1. OS/2 Version ΓòÉΓòÉΓòÉ
  3663.  
  3664. In the OS/2 version, the socket numbers are specified as an array of integers, 
  3665. in which the read socket numbers are followed by write socket numbers, followed 
  3666. by the exception pending condition socket numbers. This version monitors the 
  3667. activity on a socket by specifying the number of sockets to be checked for 
  3668. readability, readiness for writing, and exception pending conditions. 
  3669.  
  3670. #include <types.h>
  3671. #include <sys\socket.h>
  3672.  
  3673. int select(s, noreads, nowrites, noexcepts, timeout)
  3674. int *s;
  3675. int noreads;
  3676. int nowrites;
  3677. int noexcepts;
  3678. long timeout;
  3679.  
  3680.  Parameter      Description 
  3681.  
  3682.  s              Pointer to an array of socket numbers where the read socket 
  3683.                 numbers are followed by the write socket numbers, and then 
  3684.                 followed by the exception socket numbers. 
  3685.  
  3686.  noreads        Number of sockets to be checked for readability. 
  3687.  
  3688.  nowrites       Number of sockets to be checked for readiness for writing. 
  3689.  
  3690.  noexcepts      Number of sockets to be checked for exceptional pending 
  3691.                 conditions. For Network Services sockets, the only exceptional 
  3692.                 pending condition is the presence of out-of-band data in the 
  3693.                 receive buffer. 
  3694.  
  3695.  timeout        Maximum interval, in milliseconds, to wait for the selection to 
  3696.                 complete. 
  3697.  
  3698.  Description:  This call monitors activity on a set of different sockets until 
  3699.  a timeout expires, to see if any sockets are ready for reading or writing, or 
  3700.  if any exceptional conditions are pending. 
  3701.  
  3702.  If the timeout value is 0, select() does not wait before returning. If the 
  3703.  timeout value is -1, select() does not timeout, but returns when a socket 
  3704.  becomes ready. If the timeout value is a number of milliseconds, select() 
  3705.  waits for the specified interval before returning. The select() call checks 
  3706.  all indicated sockets at the same time and returns when any of them is ready. 
  3707.  
  3708.  Return and sock_errno() Values:  The return value is the number of ready 
  3709.  sockets. The return value -1 indicates an error. The return value 0 indicates 
  3710.  an expired time limit. If the return value is greater than 0, the socket 
  3711.  numbers in s that were not ready are set to -1. You can get the specific error 
  3712.  code by calling sock_errno() or psock_errno(). 
  3713.  
  3714.  
  3715.            sock_errno() Value Description 
  3716.  
  3717.       SOCECOMMSYS             Internal communications error.  Contact IBM 
  3718.                               Service. 
  3719.  
  3720.       SOCEFAULT               Using the s parameter results in an attempt to 
  3721.                               access memory outside the caller address space. 
  3722.  
  3723.       SOCEINTR                Call interrupted. 
  3724.  
  3725.       SOCEINVAL               One of the parameters has an invalid value. 
  3726.  
  3727.       SOCENOTSOCK             The s parameter is not a valid socket descriptor. 
  3728.  
  3729.  Examples:  The following is an example of the OS/2 version of the select() 
  3730.  call. 
  3731.  
  3732.   #define MAX_TIMEOUT  1000
  3733.  
  3734.   /* input_ready(insock)- Check to see if there is available input on
  3735.    * socket insock.
  3736.    * Returns 1 if input is available.
  3737.    *         0 if input is not available.
  3738.    *        -1 on error.
  3739.    */
  3740.  
  3741.    int input_ready(insock)
  3742.    int insock;                 /* input socket descriptor */
  3743.  
  3744.    {
  3745.      int socks[1];    /* array of sockets */
  3746.      long timeout = MAX_TIMEOUT;
  3747.  
  3748.      /* put socket to check in socks[] */
  3749.      socks[0] = insock;
  3750.  
  3751.      /* check for READ availability on this socket */
  3752.      return select(socks, 1, 0, 0, timeout);
  3753.    }
  3754.  
  3755.  
  3756. ΓòÉΓòÉΓòÉ 6.14.2. BSD Version ΓòÉΓòÉΓòÉ
  3757.  
  3758. The BSD version monitors the activity on sockets by specifying a set mask 
  3759. (fd_set) of socket numbers for which the caller wants to read the data, write 
  3760. the data, and check exception pending conditions. The BSD version provides 
  3761. FD_SET, FD_CLR, FD_ISSET, and FD_ZERO macros to add or delete socket numbers 
  3762. from the set mask. 
  3763.  
  3764. Note:  You must define #define BSD_SELECT before including the Network Services 
  3765. header files to access the BSD version of the select() call. Otherwise, the 
  3766. OS/2 version is assumed. 
  3767.  
  3768. #define BSD_SELECT
  3769. #include <types.h>
  3770. #include <sys\select.h>
  3771. #include <sys\time.h>
  3772.  
  3773. int select(nfds, readfds, writefds, exceptfds, timeout)
  3774. int nfds;
  3775. fd_set *readfds;
  3776. fd_set *writefds;
  3777. fd_set *exceptfds;
  3778. struct timeval *timeout;
  3779.  
  3780.  Parameter      Description 
  3781.  
  3782.  nfds           The range of socket descriptors to be checked. select() tests 
  3783.                 socket descriptors in the range of 0 to (nfds - 1). 
  3784.  
  3785.  readfds        Pointer to a bit mask of descriptors to be checked for reading. 
  3786.  
  3787.  writefds       Pointer to a bit mask of descriptors to be checked for writing. 
  3788.  
  3789.  exceptfds      Pointer to a bit mask of descriptors to be checked for 
  3790.                 exceptional pending conditions. For Network Services sockets, 
  3791.                 the only exceptional pending condition is the presence of 
  3792.                 out-of-band data in the receive buffer. 
  3793.  
  3794.  timeout        Pointer to the time to wait for the select() call to complete. 
  3795.  
  3796.  Description:  This call monitors activity on a set of different sockets until 
  3797.  a timeout expires, to see if any sockets are ready for reading or writing, or 
  3798.  if any exceptional conditions are pending. 
  3799.  
  3800.  If timeout is a NULL pointer, the call blocks indefinitely until one of the 
  3801.  requested conditions is satisfied. If timeout is non-NULL, it specifies the 
  3802.  maximum time to wait for the call to complete. If the timeout parameter points 
  3803.  to a zeroed timeval structure, a set of sockets is returned immediately. The 
  3804.  timeval structure is defined in the <SYS\TIME.H> header file and contains the 
  3805.  following fields: 
  3806.  
  3807.  
  3808.            Field          Description 
  3809.  
  3810.       tv_sec              Number of seconds 
  3811.  
  3812.       tv_usec             Number of microseconds 
  3813.  
  3814.  A bit mask is made up of an array of integers. Macros are provided to 
  3815.  manipulate the bit masks. 
  3816.  
  3817.  
  3818.            Macro                                   Description 
  3819.  
  3820.       FD_SET(socket, bit_mask_address)             Sets the bit for the socket 
  3821.                                                    in the bit mask pointed to 
  3822.                                                    by bit_mask_address. 
  3823.  
  3824.       FD_CLR(socket, bit_mask_address)             Clears the bit. 
  3825.  
  3826.       FD_ISSET(socket, bit_mask_address)           Returns a non-zero value if 
  3827.                                                    the bit is set for this 
  3828.                                                    socket descriptor; 
  3829.                                                    otherwise, it returns zero. 
  3830.  
  3831.       FD_ZERO(socket, bit_mask_address)            Clears the entire bit mask 
  3832.                                                    for all socket descriptors. 
  3833.  
  3834.  Notes 
  3835.  
  3836.    1. For macros FD_SET, FD_CLR, FD_ISSET, and FD_ZERO, define the parameters 
  3837.       socket and bit_mask_address in the following manner: 
  3838.  
  3839.             int socket;
  3840.             struct fd_set *bit_mask_address;
  3841.  
  3842.    2. The first nfds descriptors in each bit mask are tested for the specified 
  3843.       condition. 
  3844.  
  3845.    3. A socket descriptor with a value of 8 is actually the 9th descriptor in 
  3846.       the fd_set (the socket descriptor value of 0 is the first descriptor). To 
  3847.       check the socket descriptor 8, nfds would have to be greater than or 
  3848.       equal to 9. 
  3849.  
  3850.    4. Socket descriptors are specified by setting bits in a bit mask. 
  3851.  
  3852.    5. Setting any of the descriptor pointers to zero indicates that no checks 
  3853.       are to be made for the conditions. For example, setting exceptfds to be a 
  3854.       NULL pointer causes the select call to check for read and write 
  3855.       conditions only. 
  3856.  
  3857.  Return and sock_errno() Values:  The return value is the total number of ready 
  3858.  sockets (in all bit masks). The return value -1 indicates an error. The return 
  3859.  value 0 indicates an expired time limit. If the return value is greater than 
  3860.  0, the socket descriptors in each bit mask that are ready are set to 1. All 
  3861.  others are set to 0. You can get the specific error code by calling 
  3862.  sock_errno() or psock_errno(). 
  3863.  
  3864.  
  3865.            sock_errno() Value Description 
  3866.  
  3867.       SOCECOMMSYS             Internal communications error.  Contact IBM 
  3868.                               Service. 
  3869.  
  3870.       SOCEFAULT               The address is not valid. 
  3871.  
  3872.       SOCEINTR                Call interrupted. 
  3873.  
  3874.       SOCEINVAL               One of the parameters has an invalid value. 
  3875.  
  3876.       SOCENOTSOCK             One of the sockets in the bit masks is not a 
  3877.                               valid socket descriptor. 
  3878.  
  3879.  Examples:  The following is an example of the BSD version of the select() 
  3880.  call. 
  3881.  
  3882.   #define BSD_SELECT
  3883.   .
  3884.   .
  3885.   .
  3886.   fd_set readsocks;
  3887.   fd_set writesocks;
  3888.   fd_set exceptsocks;
  3889.   struct timeval timeout;
  3890.   int read_socket;
  3891.   int write_socket;
  3892.   int max_socket;
  3893.   int number_found;
  3894.   .
  3895.   .
  3896.   .
  3897.  
  3898.   /* return immediately if nothing is ready */
  3899.  
  3900.   timeout.tv_usec = 0;
  3901.   timeout.tv_sec = 0;
  3902.  
  3903.   /* initialize all the bitmasks to zero */
  3904.  
  3905.   FD_ZERO(&readsocks);
  3906.   FD_ZERO(&writesocks);
  3907.   FD_ZERO(&exceptsocks);
  3908.  
  3909.   /* check for ability to read on read_sock, write on write_sock
  3910.    * don't care about exception conditions (OOB data) */
  3911.  
  3912.   FD_SET(read_socket, &readsocks);
  3913.   FD_SET(write_socket, &writesocks);
  3914.  
  3915.   /* figure out the highest socket number to be checked in the bitmasks */
  3916.  
  3917.   if (read_socket > write_socket)
  3918.      max_socket = read_socket;
  3919.   else
  3920.      max_socket = write_socket;
  3921.  
  3922.   /* issue the select, it returns number of sockets ready,
  3923.    * or -1 if none */
  3924.  
  3925.   number_found = select(max_socket+1, &readsocks, &writesocks, &exceptsocks,
  3926.                         &timeout);
  3927.  
  3928.   if (number_found > 0)
  3929.   {
  3930.       if (FD_ISSET(read_socket, &readsocks))
  3931.       {
  3932.          /* can read data from read_socket */
  3933.       }
  3934.       else if (FD_ISSET(write_socket, &writesocks))
  3935.       {
  3936.          /* can write data on write_socket */
  3937.       }
  3938.   }
  3939.  
  3940.  
  3941. ΓòÉΓòÉΓòÉ 6.15. send() ΓòÉΓòÉΓòÉ
  3942.  
  3943. Sends data on a connected socket. 
  3944.  
  3945. #include <types.h>
  3946. #include <sys\socket.h>
  3947.  
  3948. int send(s, msg, len, flags)
  3949. int s;
  3950. char *msg;
  3951. int len;
  3952. int flags;
  3953.  
  3954.  Parameter    Description 
  3955.  
  3956.  s            Socket descriptor. 
  3957.  
  3958.  msg          Pointer to a buffer containing the message to transmit. 
  3959.  
  3960.  len          Length of the message pointed to by the msg parameter. 
  3961.  
  3962.  flags        Set by specifying one or more of the following flags. If you 
  3963.               specify more than one flag, use the logical OR operator (|) to 
  3964.               separate them. Setting this parameter is supported for sockets in 
  3965.               the internet domain only. 
  3966.  
  3967.               MSG_OOB                Sends out-of-band data on sockets that 
  3968.                                      support SOCK_STREAM communication. 
  3969.  
  3970.               MSG_DONTROUTE          The SO_DONTROUTE option is turned on for 
  3971.                                      the duration of the operation.  This is 
  3972.                                      usually used only by diagnostic or routing 
  3973.                                      programs. 
  3974.  
  3975.  Description:  This call sends data on the socket with descriptor s. The send() 
  3976.  call applies to connected sockets. For information on how to use send() with 
  3977.  datagram and raw sockets, see "Datagram or raw sockets".. 
  3978.  
  3979.  If the socket send buffer does not have any space available of the address 
  3980.  buffer to be sent, the send() call normally blocks, unless the socket is 
  3981.  placed in nonblocking mode. See ioctl() for a description of how to set 
  3982.  nonblocking mode. Use the select() call to determine when it is possible to 
  3983.  send more data. 
  3984.  
  3985.  Return and sock_errno() Values:  If successful, the return value is the number 
  3986.  of bytes sent.  Successful completion does not guarantee delivery of the data 
  3987.  to the receiver. The return value -1 indicates an error was detected on the 
  3988.  sending side of the connection. You can get the specific error code by calling 
  3989.  sock_errno() or psock_errno(). 
  3990.  
  3991.  
  3992.            sock_errno() Value    Description 
  3993.  
  3994.       SOCECOMMSYS                Internal communications error.  Contact IBM 
  3995.                                  Service. 
  3996.  
  3997.       SOCEDESTADDRREQ            Destination address required. 
  3998.  
  3999.       SOCEFAULT                  Using the msg and len parameters results in an 
  4000.                                  attempt to access memory outside the caller 
  4001.                                  address space. 
  4002.  
  4003.       SOCEINVAL                  One of the parameters has an invalid value. 
  4004.  
  4005.       SOCENOBUFS                 No buffer space is available to send the 
  4006.                                  message. 
  4007.  
  4008.       SOCENOTCONN                The socket is not connected. 
  4009.  
  4010.       SOCENOTSOCK                The s parameter is not a valid socket 
  4011.                                  descriptor. 
  4012.  
  4013.       SOCEWOULDBLOCK             The s parameter is in nonblocking mode and the 
  4014.                                  data cannot be sent without blocking, or the 
  4015.                                  SO_SNDTIMEO option has been set for socket s 
  4016.                                  and the timeout expired before any data was 
  4017.                                  sent. 
  4018.  
  4019.  
  4020. ΓòÉΓòÉΓòÉ 6.16. sendmsg() ΓòÉΓòÉΓòÉ
  4021.  
  4022. Sends data and control information on a specified socket. 
  4023.  
  4024. #include <types.h>
  4025. #include <sys\socket.h>
  4026.  
  4027. int sendmsg(s, msg, flags)
  4028. int s;
  4029. struct msghdr *msg;
  4030. int flags;
  4031.  
  4032.  Parameter    Description 
  4033.  
  4034.  s            Socket descriptor. 
  4035.  
  4036.  msg          Pointer to a message header containing a message to be sent. 
  4037.  
  4038.  flags        Set by specifying one or more of the following flags. If you 
  4039.               specify more than one flag, use the logical OR operator (|) to 
  4040.               separate them. Setting this parameter is supported only for 
  4041.               sockets in the internet domain. 
  4042.  
  4043.               MSG_OOB                Sends out-of-band data on the socket. 
  4044.  
  4045.               MSG_DONTROUTE          The SO_DONTROUTE option is turned on for 
  4046.                                      the duration of the operation.  This is 
  4047.                                      usually used only by diagnostic or routing 
  4048.                                      programs. 
  4049.  
  4050.  Description: This call sends a msghdr structure on a socket with descriptor s. 
  4051.  
  4052.  Parameter            Description 
  4053.  
  4054.  msg_name             The optional pointer to the buffer containing the 
  4055.                       recipient address. 
  4056.  
  4057.  msg_namelen          The size of the address buffer. 
  4058.  
  4059.  msg_iov              An array of iovec buffers containing the message. 
  4060.  
  4061.  msg_iovlen           The number of elements in the msg_iov array. 
  4062.  
  4063.  msg_accreights       The access rights recived.  This field is ignored. 
  4064.  
  4065.  msg_accrightslen     The length of the access right received.  This field is 
  4066.                       ignored. 
  4067.  
  4068.  The sendmsg() call applies to any socket. 
  4069.  
  4070.  This call returns the length of the data sent. If the socket with descriptor s 
  4071.  is not ready for sending data, the sendmsg() call waits unless the socket is 
  4072.  in nonblocking mode. See ioctl() for a description of how to set nonblocking 
  4073.  mode. 
  4074.  
  4075.  Return and sock_errno() Values:  If successful, the return value is the number 
  4076.  of bytes sent. Successful completion does not guarantee delivery of the data 
  4077.  to the receiver. The return value -1 indicates an error was detected on the 
  4078.  sending side of the connection. You can get the specific error code by calling 
  4079.  sock_errno() or psock_errno(). 
  4080.  
  4081.  
  4082.            sock_errno() Value    Description 
  4083.  
  4084.       SOCECOMMSYS                Internal communications error.  Contact IBM 
  4085.                                  Service. 
  4086.  
  4087.       SOCEFAULT                  Using msg results in an attempt to access 
  4088.                                  memory outside the caller address space. 
  4089.  
  4090.       SOCEINVAL                  msg_namelen is not the size of a valid address 
  4091.                                  for the specified address family. 
  4092.  
  4093.       SOCEMSGSIZE                The message was larger than the size of the 
  4094.                                  socket send buffer and could not be sent as a 
  4095.                                  single datagram. 
  4096.  
  4097.       SOCENOBUFS                 No buffer space is available to send the 
  4098.                                  message. 
  4099.  
  4100.       SOCENOTCONN                The socket is not connected. 
  4101.  
  4102.       SOCENOTSOCK                The s parameter is not a valid socket 
  4103.                                  descriptor. 
  4104.  
  4105.       SOCEWOULDBLOCK             The s parameter is in nonblocking mode and the 
  4106.                                  data cannot be sent without blocking, or the 
  4107.                                  SO_SNDTIMEO option has been set for socket s 
  4108.                                  and the timeout expired before any data was 
  4109.                                  sent. 
  4110.  
  4111.  
  4112. ΓòÉΓòÉΓòÉ 6.17. sendto() ΓòÉΓòÉΓòÉ
  4113.  
  4114. Sends data on a socket. 
  4115.  
  4116. #include <types.h>
  4117. #include <sys\socket.h>
  4118.  
  4119. int sendto(s, msg, len, flags, to, tolen)
  4120. int s;
  4121. char *msg;
  4122. int len;
  4123. int flags;
  4124. struct sockaddr *to;
  4125. int tolen;
  4126.  
  4127.  Parameter   Description 
  4128.  
  4129.  s           Socket descriptor. 
  4130.  
  4131.  msg         Pointer to the buffer containing the message to transmit. 
  4132.  
  4133.  len         Length of the message in the buffer pointed to by the msg 
  4134.              parameter. 
  4135.  
  4136.  flags       Set to 0 or one or more of the following flags. If you specify 
  4137.              more than one flag, use the logical OR operator (|) to separate 
  4138.              them. Setting this parameter is supported only for sockets in the 
  4139.              internet domain. 
  4140.  
  4141.              MSG_OOB                  Sends out-of-band data on the socket. 
  4142.  
  4143.              MSG_DONTROUTE            The SO_DONTROUTE option is turned on for 
  4144.                                       the duration of the operation. This is 
  4145.                                       usually used only by diagnostic or 
  4146.                                       routing programs. 
  4147.  
  4148.  to          Pointer to a sockaddr structure (buffer) containing the 
  4149.              destination address. 
  4150.  
  4151.  tolen       Size in bytes of the buffer pointed to by the to parameter. 
  4152.  
  4153.  Description:  This call sends data on the socket with descriptor s. The 
  4154.  sendto() call applies to connected or unconnected sockets. For unconnected 
  4155.  datagram and raw sockets, the sendto() call sends data to the specified 
  4156.  destination address. For stream and sequenced packet sockets, the destination 
  4157.  address is ignored. 
  4158.  
  4159.  Datagram sockets are connected by calling connect(). This identifies the peer 
  4160.  to send or receive the datagram.  After a datagram socket is connected to a 
  4161.  peer, you can still use the sendto() call, but a destination address cannot be 
  4162.  included. 
  4163.  
  4164.  To change the peer address when using connected datagram sockets, issue a 
  4165.  connect() call with a null address.  Specifying a null address on a connected 
  4166.  datagram socket removes the peer address specification.  You can 1 address or 
  4167.  issue a connect() call to connect to a different peer. For more information on 
  4168.  connecting datagram sockets and specifying null addresses, see "Datagram or 
  4169.  raw sockets".. 
  4170.  
  4171.  Return and sock_errno() Values:  If successful, the return value is the number 
  4172.  of bytes sent.  Successful completion does not guarantee delivery of the data 
  4173.  to the receiver. The return value -1 indicates an error was detected on the 
  4174.  sending side. You can get the specific error code by calling sock_errno() or 
  4175.  psock_errno(). 
  4176.  
  4177.  
  4178.            sock_errno() Value      Descriptioun 
  4179.  
  4180.       SOCECOMMSYS                  Internal communications error.  Contact IBM 
  4181.                                    Service. 
  4182.  
  4183.       SOCEDESTADDRREQ              Destination address required. 
  4184.  
  4185.       SOCEFAULT                    Using the msg and len parameters results in 
  4186.                                    an attempt to access memory outside the 
  4187.                                    caller address space. 
  4188.  
  4189.       SOCEINVAL                    The tolen parameter is not the size of a 
  4190.                                    valid address for the specified address 
  4191.                                    family. 
  4192.  
  4193.       SOCEMSGSIZE                  The message was larger than the size of the 
  4194.                                    socket send buffer and could not be sent as 
  4195.                                    a single datagram. 
  4196.  
  4197.       SOCENOBUFS                   No buffer space is available to send the 
  4198.                                    message. 
  4199.  
  4200.       SOCENOTCONN                  The socket is not connected. 
  4201.  
  4202.       SOCENOTSOCK                  The s parameter is not a valid socket 
  4203.                                    descriptor. 
  4204.  
  4205.       SOCEWOULDBLOCK               The s parameter is in nonblocking mode and 
  4206.                                    the data cannot be sent without blocking, or 
  4207.                                    the SO_SNDTIMEO option has been set for 
  4208.                                    socket s and the timeout expired before any 
  4209.                                    data was sent. 
  4210.  
  4211.  
  4212. ΓòÉΓòÉΓòÉ 6.18. setsockopt() ΓòÉΓòÉΓòÉ
  4213.  
  4214. Sets options associated with a socket. 
  4215.  
  4216. #include <types.h>
  4217. #include <sys\socket.h>
  4218.  
  4219. int setsockopt(s, level, optname, optval, optlen)
  4220. int s;
  4221. int level;
  4222. int optname;
  4223. char *optval;
  4224. int optlen;
  4225.  
  4226.  Parameter      Description 
  4227.  
  4228.  s              Socket descriptor 
  4229.  
  4230.  level          Specifies the option level that is being set 
  4231.  
  4232.  optname        Name of a specified socket option 
  4233.  
  4234.  optval         Pointer to the option data 
  4235.  
  4236.  optlen         Length of the option data 
  4237.  
  4238.  Description:  This call sets options associated with a socket such as enabling 
  4239.  debugging at the socket or protocol level, control timeouts, or permit socket 
  4240.  data broadcast. Options can exist at the socket or the protocol level; options 
  4241.  are always present at the highest socket level. When setting socket options, 
  4242.  the level of the option and the name of the option must be specified. The 
  4243.  following table lists the supported levels: 
  4244.  
  4245.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4246.   Γöé Table 15. Supported Levels            Γöé
  4247.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4248.   Γöé SUPPORTED LEVEL    Γöé #DEFINE IN        Γöé
  4249.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4250.   Γöé SOL_SOCKET      Γöé <SYS\SOCKET.H>      Γöé
  4251.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4252.   Γöé IPPROTO_IP      Γöé <NETINET\IN.H>      Γöé
  4253.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4254.   Γöé IPPROTO_TCP      Γöé <NETINET\IN.H>      Γöé
  4255.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4256.   Γöé NBPROTO_NB      Γöé <NETNB\NB.H>       Γöé
  4257.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4258.  
  4259.  The optval and optlen parameters are used to pass data used by the particular 
  4260.  set command. The optval parameter points to a buffer containing the data 
  4261.  needed by the set command. The optval parameter is optional and if data is not 
  4262.  needed by the command, can be set to the NULL pointer. The optlen parameter 
  4263.  must be set to the size of the data or data type pointed to by optval. For 
  4264.  socket options that are boolean, the option is enabled if optval is nonzero 
  4265.  and disabled if optval is zero. 
  4266.  
  4267.  The following tables list the supported options for setsockopt() at each level 
  4268.  (SOL_SOCKET, IPPROTO_IP, IPPROTO_TCP, NBPROTO_NB). Detailed descriptions of 
  4269.  the options follow each table. 
  4270.  
  4271.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4272.   Γöé Table 16. Supported setsockopt() Socket Options for SOL_SOCKET     Γöé
  4273.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4274.   Γöé        Γöé              Γöé  DOMAINS Γöé DATA  Γöé BOOLEAN  Γöé
  4275.   Γöé OPTION NAME  Γöé DESCRIPTION        Γöé   *   Γöé TYPE  Γöé OR VALUE Γöé
  4276.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4277.   Γöé SO_BROADCAST Γöé allows sending of broad- Γöé I, N   Γöé int   Γöé boolean  Γöé
  4278.   Γöé        Γöé cast messages       Γöé      Γöé     Γöé      Γöé
  4279.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4280.   Γöé SO_DEBUG   Γöé turns on recording of   Γöé I, L   Γöé int   Γöé boolean  Γöé
  4281.   Γöé        Γöé debugging information   Γöé      Γöé     Γöé      Γöé
  4282.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4283.   Γöé SO_DONTROUTE Γöé bypasses routing tables  Γöé I, L   Γöé int   Γöé boolean  Γöé
  4284.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4285.   Γöé SO_KEEPALIVE Γöé keeps connections alive  Γöé I     Γöé int   Γöé boolean  Γöé
  4286.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4287.   Γöé SO_LINGER   Γöé lingers on close if data Γöé I     Γöé struct Γöé value   Γöé
  4288.   Γöé        Γöé present          Γöé      Γöé linger Γöé      Γöé
  4289.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4290.   Γöé SO_OOBINLINE Γöé leaves received OOB data Γöé I     Γöé int   Γöé boolean  Γöé
  4291.   Γöé        Γöé in-line          Γöé      Γöé     Γöé      Γöé
  4292.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4293.   Γöé SO_RCVBUF   Γöé receives buffer size   Γöé I, L, N  Γöé long  Γöé value   Γöé
  4294.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4295.   Γöé SO_RCVLOWAT  Γöé receives low-water mark  Γöé I, L   Γöé int   Γöé value   Γöé
  4296.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4297.   Γöé SO_RCVTIMEO  Γöé receives timeout     Γöé I, L, N  Γöé struct Γöé value   Γöé
  4298.   Γöé        Γöé              Γöé      Γöé timevalΓöé      Γöé
  4299.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4300.   Γöé SO_REUSEADDR Γöé allows local address   Γöé I, N   Γöé int   Γöé boolean  Γöé
  4301.   Γöé        Γöé reuse           Γöé      Γöé     Γöé      Γöé
  4302.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4303.   Γöé SO_REUSEPORT Γöé allows a socket to reuse Γöé I     Γöé int   Γöé boolean  Γöé
  4304.   Γöé        Γöé a local address and    Γöé      Γöé     Γöé      Γöé
  4305.   Γöé        Γöé local port        Γöé      Γöé     Γöé      Γöé
  4306.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4307.   Γöé SO_SNDBUF   Γöé sends buffer size     Γöé I, L, N  Γöé long  Γöé value   Γöé
  4308.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4309.   Γöé SO_SNDLOWAT  Γöé sends low-water mark   Γöé I. L   Γöé int   Γöé value   Γöé
  4310.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4311.   Γöé SO_SNDTIMEO  Γöé sends timeout       Γöé I, L, N  Γöé struct Γöé value   Γöé
  4312.   Γöé        Γöé              Γöé      Γöé timevalΓöé      Γöé
  4313.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4314.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4315.   Γöé NOTE:  * This column specifies I for internet, L for Local IPC, and N  Γöé
  4316.   Γöé for NetBIOS communication domains.                   Γöé
  4317.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4318.  
  4319.  The following options are recognized for option level SOL_SOCKET: 
  4320.  
  4321.  
  4322.            Option                 Description 
  4323.  
  4324.       SO_BROADCAST                (datagram sockets only) Sets the ability to 
  4325.                                   broadcast messages. If this option is 
  4326.                                   enabled, it allows the application to send 
  4327.                                   broadcast messages over s, if the interface 
  4328.                                   specified in the destination supports 
  4329.                                   broadcasting of packets. 
  4330.  
  4331.       SO_DEBUG                    Sets the ability to record debug information 
  4332.                                   for a socket. 
  4333.  
  4334.       SO_DONTROUTE                Sets the ability for the socket to bypass the 
  4335.                                   routing of outgoing messages. When this 
  4336.                                   option is enabled, it causes outgoing 
  4337.                                   messages to bypass the standard routing 
  4338.                                   algorithm and be directed to the appropriate 
  4339.                                   network interface according to the network 
  4340.                                   portion of the destination address. When 
  4341.                                   enabled, packets can be sent to directly 
  4342.                                   connected networks (networks for which this 
  4343.                                   host has an interface) only. 
  4344.  
  4345.       SO_KEEPALIVE                (stream sockets only) Sets the ability of the 
  4346.                                   socket to send keepalive packets that keep 
  4347.                                   the connection alive. TCP uses a timer called 
  4348.                                   the keepalive timer. This timer is used to 
  4349.                                   monitor idle connections that may have been 
  4350.                                   disconnected because of a peer crash or 
  4351.                                   timeout. If this option is set to ON, a 
  4352.                                   keepalive packet is periodically sent to the 
  4353.                                   peer. This is mainly used to allow servers to 
  4354.                                   close connections that are no longer active 
  4355.                                   as a result of clients going away without 
  4356.                                   properly closing connections. 
  4357.  
  4358.       SO_LINGER                   (stream sockets only) Sets the ability of the 
  4359.                                   socket to linger on close. When this option 
  4360.                                   is enabled, and data is present in the socket 
  4361.                                   send buffer when soclose() is called, the 
  4362.                                   calling appl  ication is blocked in soclose() 
  4363.                                   until the data is transmitted or until the 
  4364.                                   linger timeout expires.  If the linger 
  4365.                                   timeout expires, the unsent data is 
  4366.                                   discarded, the connection is reset, and 
  4367.                                   soclose() returns -1 with an error value of 
  4368.                                   SOCEWOULDBLOCK.  Even though soclose() 
  4369.                                   returned an error, the socket is closed (no 
  4370.                                   further calls can be made for the socket). 
  4371.                                   Note that a linger timeout of zero results in 
  4372.                                   no lingering if unsent data exists.  A 
  4373.                                   timeout of zero expires immediately when the 
  4374.                                   call is issued, resulting in discarding any 
  4375.                                   unsent data and resetting the connection. 
  4376.  
  4377.                                   When this option is disabled (the default), 
  4378.                                   soclose() does not block when unsent data is 
  4379.                                   present at the time of the call. Rather, the 
  4380.                                   soclose() completes immediately and TCP 
  4381.                                   continues to attempt to send the remaining 
  4382.                                   data before closing the connection. The 
  4383.                                   application has no guarantee that the data is 
  4384.                                   successfully sent, since errors encountered 
  4385.                                   on the connection after the socket is closed 
  4386.                                   cannot be reported to the application. 
  4387.  
  4388.       SO_OOBINLINE                (stream sockets only) Sets the ability of the 
  4389.                                   socket to receive out-of-band data. As stated 
  4390.                                   in TCP/IP Illustrated, Volume 1: The 
  4391.                                   Protocols out-of-band data is "a logically 
  4392.                                   separate data path using the same connection 
  4393.                                   as the normal data path." 
  4394.  
  4395.                                   When this option is enabled, it causes 
  4396.                                   out-of-band data to be placed in the normal 
  4397.                                   data input queue as it is received, making it 
  4398.                                   available to recv(), and recvfrom(), without 
  4399.                                   having to specify the MSG_OOB flag in those 
  4400.                                   calls. When this option is disabled, it 
  4401.                                   causes out-of-band data to be placed in the 
  4402.                                   priority data input queue as it is received, 
  4403.                                   making it available to recv(), and 
  4404.                                   recvfrom(), only by specifying the MSG_OOB 
  4405.                                   flag in those calls. 
  4406.  
  4407.       SO_RCVBUF                   Sets buffer size for input. This option sets 
  4408.                                   the size of the receive buffer to the value 
  4409.                                   contained in the buffer pointed to by optval. 
  4410.                                   This allows the buffer size to be tailored 
  4411.                                   for specific application needs, such as 
  4412.                                   increasing the buffer size for high-volume 
  4413.                                   connections. 
  4414.  
  4415.       SO_RCVLOWAT                 Sets receive low-water mark that controls 
  4416.                                   when a recv() call returns when less data is 
  4417.                                   available than the recv() call is requesting. 
  4418.                                   If at least SO_RCVLOWAT bytes are available, 
  4419.                                   the recv() call returns those bytes.  The 
  4420.                                   default is 1 for both TCP and UDP sockets. 
  4421.  
  4422.       SO_RCVTIMEO                 Sets receive timeout. This value limits the 
  4423.                                   length of a blocking receive call.  This 
  4424.                                   value is ignored for non-blocking calls. 
  4425.  
  4426.       SO_REUSEADDR                (stream and datagram sockets only) Allows a 
  4427.                                   socket to reuse a local address. When 
  4428.                                   enabled, this option allows local addresses 
  4429.                                   that are already in use to be bound. This 
  4430.                                   alters the normal algorithm used in the 
  4431.                                   bind() call. Network Services checks at 
  4432.                                   connect time to be sure that no local address 
  4433.                                   and port have the same foreign address and 
  4434.                                   port. The error SOCEADDRINUSE is returned if 
  4435.                                   the association already exists. 
  4436.  
  4437.       SO_REUSEPORT                (stream and datagram sockets only) Allows a 
  4438.                                   socket to reuse a local address and port. 
  4439.                                   When enabled, this option allows local 
  4440.                                   addresses and ports that are already in use 
  4441.                                   to be bound. This alters the normal algorithm 
  4442.                                   used in the bind() call. This option is 
  4443.                                   normally only used by multicasting 
  4444.                                   applications. 
  4445.  
  4446.       SO_SNDBUF                   Sets buffer size for output. This option sets 
  4447.                                   the size of the send buffer to the value 
  4448.                                   contained in the buffer pointed to by optval. 
  4449.                                   This allows the send buffer size to be 
  4450.                                   tailored for specific application needs, such 
  4451.                                   as increasing the buffer size for high-volume 
  4452.                                   connections. 
  4453.  
  4454.       SO_SNDLOWAT                 Sets send low-water mark that influences 
  4455.                                   socket flow control operations.  SO_SNDLOWAT 
  4456.                                   is used for TCP sockets, but not UDP sockets. 
  4457.                                   During a send operation, if the socket code 
  4458.                                   must wait for space to be available in the 
  4459.                                   send buffer before sending data, the socket 
  4460.                                   waits for at least SO_SNDLOWAT bytes to be 
  4461.                                   available in the send buffer before sending 
  4462.                                   the data.  The default value is the size of a 
  4463.                                   cluster mbuf. 
  4464.  
  4465.       SO_SNDTIMEO                 Sets send timeout. This value limits the 
  4466.                                   length of a blocking send call.  This value 
  4467.                                   is ignored for non-blocking calls. 
  4468.  
  4469.  struct linger: For the SO_LINGER option, optval points to a linger structure. 
  4470.  This structure is defined in <SYS\SOCKET.H> and contains the following fields: 
  4471.  
  4472.  
  4473.            Field          Description 
  4474.  
  4475.       l_onoff             Option on/off 
  4476.  
  4477.       l_linger            Linger time 
  4478.  
  4479.  The l_onoff field is set to zero if the SO_LINGER option is being disabled. A 
  4480.  nonzero value enables the option. 
  4481.  
  4482.  The l_linger field specifies the amount of time in seconds to linger on close. 
  4483.  A value of zero causes an abnormal close.  TCP discards any data still queued 
  4484.  to be sent on the connection and sends a reset to the peer.  The peer sees 
  4485.  this as an abnormal close when it gets an error on an outstanding receive. 
  4486.  
  4487.  struct timeval: For the SO_RCVTIMEO and SO_SNDTIMEO options, optval points to 
  4488.  a timeval structure.  This structure is defined in <SYS\TIME.H> and contains 
  4489.  the following fields: 
  4490.  
  4491.  
  4492.            Field          Description 
  4493.  
  4494.       tv_sec              Number of seconds 
  4495.  
  4496.       tv_usec             Number of microseconds 
  4497.  
  4498.  For the internet domain, the finest resolution is milliseconds, thus the 
  4499.  tv_usec field is converted. In this conversion, anything less than a 
  4500.  millisecond is truncated.  For example, if you call setsockopt() to set 
  4501.  tv_usec to 31, the next getsockopt() call returns a 0 for tv_usec  If you call 
  4502.  setsockopt() to set tv_usec to 1031, the next getsockopt() returns 1000. 
  4503.  
  4504.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4505.   Γöé Table 17. Supported setsockopt() Socket Options for IPPROTO_IP          Γöé
  4506.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4507.   Γöé            Γöé                 Γöé        Γöé BOOLEAN  Γöé
  4508.   Γöé OPTION NAME      Γöé DESCRIPTION           Γöé DATA TYPE   Γöé OR VALUE Γöé
  4509.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4510.   Γöé IP_ADD_MEMBERSHIP   Γöé joins a multicast group     Γöé struct    Γöé value   Γöé
  4511.   Γöé            Γöé                 Γöé ip_mreq    Γöé      Γöé
  4512.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4513.   Γöé IP_DROP_MEMBERSHIP  Γöé leaves a multicast group    Γöé struct    Γöé value   Γöé
  4514.   Γöé            Γöé                 Γöé ip_mreq    Γöé      Γöé
  4515.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4516.   Γöé IP_MULTICAST_IF    Γöé provides default interface for Γöé struct    Γöé value   Γöé
  4517.   Γöé            Γöé outgoing multicasts       Γöé in_addr    Γöé      Γöé
  4518.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4519.   Γöé IP_MULTICAST_LOOP   Γöé causes a loopback of outgoing  Γöé uchar     Γöé boolean  Γöé
  4520.   Γöé            Γöé multicast            Γöé        Γöé      Γöé
  4521.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4522.   Γöé IP_MULTICAST_TTL   Γöé provides default TTL for out-  Γöé uchar     Γöé value   Γöé
  4523.   Γöé            Γöé going multicast         Γöé        Γöé      Γöé
  4524.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4525.   Γöé IP_OPTIONS      Γöé provides options in IP header  Γöé void *    Γöé value   Γöé
  4526.   Γöé            Γöé to be included in outgoing   Γöé        Γöé      Γöé
  4527.   Γöé            Γöé datagrams            Γöé        Γöé      Γöé
  4528.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4529.   Γöé IP_RECVDSTADDR    Γöé allows queueing of IP destina- Γöé int      Γöé boolean  Γöé
  4530.   Γöé            Γöé tion address          Γöé        Γöé      Γöé
  4531.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4532.   Γöé IP_TOS        Γöé gives type of service for out- Γöé int      Γöé boolean  Γöé
  4533.   Γöé            Γöé going datagrams         Γöé        Γöé      Γöé
  4534.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4535.   Γöé IP_TTL        Γöé provides time to live for out- Γöé int      Γöé value   Γöé
  4536.   Γöé            Γöé going datagrams         Γöé        Γöé      Γöé
  4537.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4538.  
  4539.  The following options are recognized for option level IPPROTO_IP and are 
  4540.  supported for the internet communication domain only. 
  4541.  
  4542.  
  4543.            Option                 Description 
  4544.  
  4545.       IP_ADD_MEMBERSHIP           Sets to join a multicast group.  Specify the 
  4546.                                   IP multicast address and the local IP address 
  4547.                                   of the interface. If the interface address is 
  4548.                                   INADDR_ANY, the interface picked is based on 
  4549.                                   the routing table. 
  4550.  
  4551.       IP_DROP_MEMBERSHIP          Sets to leave a multicast group.  Specify the 
  4552.                                   IP multicast address and the local IP address 
  4553.                                   of the interface. If the interface address is 
  4554.                                   INADDR_ANY, all interfaces are searched for 
  4555.                                   this IP multicast address. 
  4556.  
  4557.       IP_MULTICAST_IF             Sets the default interface for outgoing 
  4558.                                   multicasts. Normally this is the interface 
  4559.                                   selected for an outgoing interface based on 
  4560.                                   the destination.  This default can be 
  4561.                                   overridden by specifying the IP address of 
  4562.                                   the outgoing interface. 
  4563.  
  4564.       IP_MULTICAST_LOOP           Enables or disables loopback of outgoing 
  4565.                                   multicasts. If this value is set to 0, 
  4566.                                   packets are not looped back and delivered to 
  4567.                                   the transmitting interface, even if the 
  4568.                                   interface is a member of the multicasting 
  4569.                                   group. If this value is set to 1, packets are 
  4570.                                   looped back if the interface is a member of 
  4571.                                   the multicasting group.  The default value is 
  4572.                                   1. 
  4573.  
  4574.       IP_MULTICAST_TTL            Sets the default TTL for outgoing multicasts. 
  4575.                                   The default is 1, which causes multicast 
  4576.                                   datagrams to remain on the local network. 
  4577.                                   This value is also used by multicast routers 
  4578.                                   to have a threshold policy to drop multicast 
  4579.                                   packets. Packets can be dropped by a router 
  4580.                                   even though its TTL is not 0. 
  4581.  
  4582.       IP_OPTIONS                  Sets options in the IP header to be included 
  4583.                                   in outgoing datagrams. 
  4584.  
  4585.       IP_RECVDSTADDR              (datagram sockets only) Enables or disables 
  4586.                                   if IP destination address is passed on the 
  4587.                                   recvmsg() call. The IP destination is passed 
  4588.                                   pack in the msg_control parameter, if the 
  4589.                                   msg_controllen parameter is less than 4 
  4590.                                   bytes, the flags indicate the control 
  4591.                                   information was truncated. 
  4592.  
  4593.       IP_TOS                      Sets the type of service (TOS) used in 
  4594.                                   outgoing datagram and stream packets. 
  4595.  
  4596.       IP_TTL                      Sets the time to live (TTL) for outgoing 
  4597.                                   datagrams. A TTL value of 1 prevents packets 
  4598.                                   from being routed to other networks.  Raw 
  4599.                                   sockets default to the maximum of 255, 
  4600.                                   datagram and stream sockets default to 64. 
  4601.  
  4602.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4603.   Γöé Table 18. Supported setsockopt() Socket Options for IPPROTO_TCP         Γöé
  4604.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4605.   Γöé            Γöé                 Γöé        Γöé BOOLEAN  Γöé
  4606.   Γöé OPTION NAME      Γöé DESCRIPTION           Γöé DATA TYPE   Γöé OR VALUE Γöé
  4607.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4608.   Γöé TCP_NODELAY      Γöé indicates that the send to   Γöé int      Γöé boolean  Γöé
  4609.   Γöé            Γöé coalesce packets should not be Γöé        Γöé      Γöé
  4610.   Γöé            Γöé delayed             Γöé        Γöé      Γöé
  4611.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4612.  
  4613.  The following options are recognized for option level IPPROTO_TCP and are 
  4614.  supported for the internet communication domain only. 
  4615.  
  4616.      TCP_ socket options 
  4617.  
  4618.      IPPROTO_TCP socket options 
  4619.  
  4620.  
  4621.                 Option                 Description 
  4622.  
  4623.            TCP_NODELAY                 (stream sockets only) Setting on 
  4624.                                        disables the small packet avoidance 
  4625.                                        algorithm so that the client TCP sends 
  4626.                                        small packets as soon as possible. This 
  4627.                                        option may provide a performance 
  4628.                                        improvement for some applications on a 
  4629.                                        LAN, but can degrade performance on Wide 
  4630.                                        Area Networks (WAN). 
  4631.  
  4632.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4633.   Γöé Table 19. Supported setsockopt() Socket Options for NBPROTO_NB          Γöé
  4634.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4635.   Γöé            Γöé                 Γöé        Γöé BOOLEAN  Γöé
  4636.   Γöé OPTION NAME      Γöé DESCRIPTION           Γöé DATA TYPE   Γöé OR VALUE Γöé
  4637.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4638.   Γöé NB_DGRAM_TYPE     Γöé type of datagrams to receive  Γöé int      Γöé value   Γöé
  4639.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4640.  
  4641.  The following option is recognized for option level NBPROTO_NB and is 
  4642.  supported for the NetBIOS communication domain only. 
  4643.  
  4644.  
  4645.            Option                 Description 
  4646.  
  4647.       NB_DGRAM_TYPE               (datagram sockets only) Sets type of 
  4648.                                   datagrams to be received on the socket.  The 
  4649.                                   possible values are: 
  4650.  
  4651.                                        NB_DGRAM               The socket is to 
  4652.                                                               receive normal 
  4653.                                                               (unicast) 
  4654.                                                               datagrams only. 
  4655.                                        NB_BROADCAST           The socket is to 
  4656.                                                               receive broadcast 
  4657.                                                               datagrams only. 
  4658.                                        NB_DGRAM_ANY           The socket can 
  4659.                                                               receive both 
  4660.                                                               normal or 
  4661.                                                               broadcast 
  4662.                                                               datagrams. This 
  4663.                                   option can be changed at any time. 
  4664.  
  4665.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  4666.  return value -1 indicates an error. You can get the specific error code by 
  4667.  calling sock_errno() or psock_errno(). 
  4668.  
  4669.  
  4670.            sock_errno() Value    Description 
  4671.  
  4672.       SOCECOMMSYS                Internal communications error.  Contact IBM 
  4673.                                  Service. 
  4674.  
  4675.       SOCEFAULT                  Using optval and optlen parameters results in 
  4676.                                  an attempt to access memory outside the caller 
  4677.                                  address space. 
  4678.  
  4679.       SOCEINVAL                  One of the parameters has an invalid value. 
  4680.  
  4681.       SOCENOBUFS                 No buffer space is available. 
  4682.  
  4683.       SOCENOPROTOOPT             The optname parameter or the level parameter 
  4684.                                  is unrecognized. 
  4685.  
  4686.       SOCENOTSOCK                The s parameter is not a valid socket 
  4687.                                  descriptor. 
  4688.  
  4689.  Examples:  The following are examples of the setsockopt() call.  See 
  4690.  getsockopt() for examples of how getsockopt() retrieves the socket option 
  4691.  settings. 
  4692.  
  4693.   int rc;
  4694.   int s;
  4695.   int optval;
  4696.   struct linger lstruct;
  4697.   /* extracted from sys/socket.h */
  4698.   int setsockopt(int s, int level, int optname, char *optval, int optlen);
  4699.   .
  4700.   .
  4701.   .
  4702.   /* I want out of band data in the normal input queue. */
  4703.   optval = 1;
  4704.   rc = setsockopt(s, SOL_SOCKET, SO_OOBINLINE, (char *) &optval, sizeof(int));
  4705.  
  4706.   .
  4707.   .
  4708.   .
  4709.   /* I want to linger on close. */
  4710.   lstruct.l_onoff  = 1;
  4711.   lstruct.l_linger = 100;
  4712.   rc = setsockopt(s, SOL_SOCKET, SO_LINGER, (char *) &lstruct, sizeof(lstruct));
  4713.  
  4714.  
  4715. ΓòÉΓòÉΓòÉ 6.19. shutdown() ΓòÉΓòÉΓòÉ
  4716.  
  4717. Shuts down all or part of a full-duplex connection. 
  4718.  
  4719. int shutdown(s, howto)
  4720. int s;
  4721. int howto;
  4722.  
  4723.  Parameter       Description 
  4724.  
  4725.  s               Socket descriptor 
  4726.  
  4727.  howto           Condition of the shutdown 
  4728.  
  4729.  Description:  This call shuts down all or part of a full-duplex connection. 
  4730.  Because data flows in one direction are independent of data flowing from the 
  4731.  other direction, the shutdown call allows data flow to be stopped 
  4732.  independently in either direction or all data flows with one API call. For 
  4733.  example, you may want to stop the senders from sending data to you, but you 
  4734.  still want to send data. 
  4735.  
  4736.  Using the shutdown() call is optional. 
  4737.  
  4738.  The howto parameter sets the condition for shutting down the connection to 
  4739.  socket s. It can be set to one of the following: 
  4740.  
  4741.      0 - no more data can be received on socket s. 
  4742.      1 - no more data can be sent on socket s. 
  4743.      2 - no more data can be sent or received on socket s. 
  4744.  
  4745.  Note:  In the NetBIOS domain, the shutdown() call is valid, but the function 
  4746.         of shutdown() is not implemented.  When called, shutdown() returns a 
  4747.         successful return code, but no shutdown occurs. 
  4748.  
  4749.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  4750.  return value -1 indicates an error. You can get the specific error code by 
  4751.  calling sock_errno() or psock_errno(). 
  4752.  
  4753.  
  4754.            sock_errno() Value Description 
  4755.  
  4756.       SOCECOMMSYS             Internal communications error.  Contact IBM 
  4757.                               Service. 
  4758.  
  4759.       SOCEINVAL               The howto parameter was not set to one of the 
  4760.                               valid values. 
  4761.  
  4762.       SOCENOTSOCK             The s parameter is not a valid socket descriptor. 
  4763.  
  4764.  
  4765. ΓòÉΓòÉΓòÉ 6.20. sock_errno() ΓòÉΓòÉΓòÉ
  4766.  
  4767. Returns error code set by a socket call. 
  4768.  
  4769. #include <nerrno.h>
  4770.  
  4771.  
  4772. int sock_errno()
  4773.  
  4774. Description:  The sock_errno() call returns the last error code set by a socket 
  4775. call on this thread. 
  4776.  
  4777.  
  4778. ΓòÉΓòÉΓòÉ 6.21. socket() ΓòÉΓòÉΓòÉ
  4779.  
  4780. Creates an endpoint for communication and returns a socket descriptor 
  4781. representing the endpoint. 
  4782.  
  4783. #include <types.h>
  4784. #include <sys\socket.h>
  4785.  
  4786. int socket(domain, type, protocol)
  4787. int domain;
  4788. int type;
  4789. int protocol;
  4790.  
  4791.  Parameter      Description 
  4792.  
  4793.  domain         Communication domain requested 
  4794.  
  4795.  type           Type of socket created 
  4796.  
  4797.  protocol       Protocol requested 
  4798.  
  4799.  Description:  This call creates an endpoint for communication and returns a 
  4800.  socket descriptor representing the endpoint. Each socket type provides a 
  4801.  different communication service. 
  4802.  
  4803.  Sockets are deallocated with the soclose() call. 
  4804.  
  4805.  The domain parameter specifies a communications domain where communication is 
  4806.  to take place. This parameter specifies the protocol family that is used. 
  4807.  
  4808.  
  4809.            Protocol Family       Description 
  4810.  
  4811.       AF_OS2, AF_UNIX, or AF_LOCAL Use addresses in the Local IPC format that 
  4812.                                  take the form of OS/2 Warp Connect file and 
  4813.                                  path names. 
  4814.  
  4815.       AF_INET                    Use addresses in the internet address format. 
  4816.  
  4817.       AF_NETBIOS or AF_NB        Use addresses in the NetBIOS address format. 
  4818.  
  4819.  The type parameter specifies the type of socket created. The type is analogous 
  4820.  with the semantics of the communication requested.  These socket type 
  4821.  constants are defined in the <SYS\SOCKET.H> header file. Refer to Socket Types 
  4822.  for additional details. The types supported are: 
  4823.  
  4824.  
  4825.            Type                Description 
  4826.  
  4827.       SOCK_STREAM              Provides sequenced, two-way byte streams that 
  4828.                                are reliable and connection-oriented. It 
  4829.                                supports a mechanism for out-of-band data. 
  4830.  
  4831.                                Stream sockets are supported by the internet 
  4832.                                (AF_INET) communication domain and Local IPC 
  4833.                                (AF_OS2, AF_UNIX, or AF_LOCAL). 
  4834.  
  4835.       SOCK_SEQPACKET           Provides sequenced, two-way byte records that 
  4836.                                are reliable and connection-oriented. 
  4837.  
  4838.                                Sequenced packet sockets are supported by the 
  4839.                                NetBIOS (AF_NETBIOS or AF_NB) communication 
  4840.                                domain. 
  4841.  
  4842.       SOCK_DGRAM               Provides datagrams, which are connectionless 
  4843.                                messages whose reliability is not guaranteed. 
  4844.                                Datagrams can be received out of order, lost, or 
  4845.                                delivered multiple times. 
  4846.  
  4847.                                Datagram sockets are supported by the internet 
  4848.                                (AF_INET), Local IPC (AF_OS2, AF_UNIX, or 
  4849.                                AF_LOCAL), and NetBIOS (AF_NETBIOS or AF_NB) 
  4850.                                communication domains. 
  4851.  
  4852.       SOCK_RAW                 Provides the interface to internal protocols 
  4853.                                (such as IP and ICMP).  Raw sockets are 
  4854.                                supported by the internet (AF_INET) 
  4855.                                communication domain. 
  4856.  
  4857.  The protocol parameter specifies a particular protocol to be used with the 
  4858.  socket. If the protocol field is set to 0 (default), Network Services selects 
  4859.  the default protocol number for the domain and socket type requested. Default 
  4860.  and valid protocol number-protocol family combinations are in Default 
  4861.  Protocols. The getprotobyname() call can be used to get the protocol number 
  4862.  for a protocol with a well-known name. 
  4863.  
  4864.  Return and sock_errno() Values:  A non-negative socket descriptor return value 
  4865.  indicates success. The return value -1 indicates an error. You can get the 
  4866.  specific error code by calling sock_errno() or psock_errno(). 
  4867.  
  4868.  
  4869.            sock_errno() Value            Description 
  4870.  
  4871.       SOCECOMMSYS                        Internal communications error. 
  4872.                                          Contact IBM Service. 
  4873.  
  4874.       SOCEMFILE                          The maximum number of sockets are 
  4875.                                          currently in use. 
  4876.  
  4877.       SOCEPROTONOSUPPORT                 The protocol is not supported in the 
  4878.                                          specified domain or the protocol is 
  4879.                                          not supported for the specified socket 
  4880.                                          type. 
  4881.  
  4882.       SOCEPROTOTYPE                      The protocol is the wrong type for the 
  4883.                                          socket. 
  4884.  
  4885.  Examples:  The following are examples of the socket() call. 
  4886.  
  4887.   int s;
  4888.   struct protoent *p;
  4889.   struct protoent *getprotobyname(char *name);
  4890.   int socket(int domain, int type, int protocol); /* extracted from sys\socket.h */
  4891.   .
  4892.   .
  4893.   .
  4894.   /* Get stream socket in internet domain with default protocol. */
  4895.   s = socket(AF_INET, SOCK_STREAM, 0);
  4896.   .
  4897.   .
  4898.   .
  4899.   /* Get raw socket in internet domain for ICMP protocol. */
  4900.   p = getprotobyname("icmp");
  4901.   s = socket(AF_INET, SOCK_RAW, p->p_proto);
  4902.  
  4903.  
  4904. ΓòÉΓòÉΓòÉ 6.22. soclose() ΓòÉΓòÉΓòÉ
  4905.  
  4906. Shuts down a socket and frees resources allocated to the socket. 
  4907.  
  4908. #include <types.h>
  4909. #include <sys\socket.h>
  4910.  
  4911. int soclose(s)
  4912. int s;
  4913.  
  4914.  Parameter      Description 
  4915.  
  4916.  s              Socket descriptor 
  4917.  
  4918.  Description:  This call shuts down the socket associated with the socket 
  4919.  descriptor s, and frees resources allocated to the socket.  If s refers to a 
  4920.  connected socket, the connection is closed. 
  4921.  
  4922.  If the SO_LINGER socket option is enabled (see setsockopt() for additional 
  4923.  information), the task tries to send any queued data. If the SO_LINGER socket 
  4924.  option is disabled, the task flushes any data queued to be sent. 
  4925.  
  4926.  Return and sock_errno() Values:  The return value 0 indicates success; the 
  4927.  return value -1 indicates an error. You can get the specific error code by 
  4928.  calling sock_errno() or psock_errno(). 
  4929.  
  4930.  
  4931.            sock_errno() Value      Description 
  4932.  
  4933.       SOCECOMMSYS                  Internal communications error.  Contact IBM 
  4934.                                    Service. 
  4935.  
  4936.       SOCENOTSOCK                  The s parameter is not a valid socket 
  4937.                                    descriptor. 
  4938.  
  4939.       SOCEWOULDBLOCK               The linger option is enabled and the linger 
  4940.                                    timeout expired before unsent data could be 
  4941.                                    successfully sent. The data is discarded and 
  4942.                                    the connection is reset instead of closing 
  4943.                                    normally. 
  4944.  
  4945.  
  4946. ΓòÉΓòÉΓòÉ 6.23. writev() ΓòÉΓòÉΓòÉ
  4947.  
  4948. Writes data from a set of specified buffers on a socket. 
  4949.  
  4950. #include <types.h>
  4951. #include <sys\socket.h>
  4952.  
  4953. int writev(s, iov, iovcnt)
  4954. int s;
  4955. struc iovec *iov;
  4956. int iovcnt;
  4957.  
  4958.  Parameter      Description 
  4959.  
  4960.  s              Socket descriptor. 
  4961.  
  4962.  iov            Pointer to an array of iovec structures. 
  4963.  
  4964.  iovcnt         Number of iovec structures pointed to by the iov parameter. The 
  4965.                 maximum number of iovec structures is 32. 
  4966.  
  4967.  Description:  This call writes data on a socket with descriptor s. The data is 
  4968.  gathered from the buffers specified by iov[0]...iov[iovcnt-1]. The iovec 
  4969.  structure is defined in the <SYS\SOCKET.H> header file and contains the 
  4970.  following fields: 
  4971.  
  4972.  
  4973.            Field          Description 
  4974.  
  4975.       iov_base            Pointer to the buffer 
  4976.  
  4977.       iov_len             Length of the buffer 
  4978.  
  4979.  This call writes up to the number of bytes in the buffers pointed to by the 
  4980.  iov parameter.  This number is the sum of all iov_len fields. If the data 
  4981.  cannot be sent without blocking and the socket is in blocking mode, the 
  4982.  writev() call blocks the caller until the data can be sent. If the socket is 
  4983.  in a nonblocking mode, writev() returns -1 and sets the return code to 
  4984.  SOCEWOULDBLOCK. See ioctl() for a description of how to set nonblocking mode. 
  4985.  
  4986.  For datagram sockets, this call sends the entire datagram, provided it fits 
  4987.  into the socket write buffer. If the socket write buffer does not have any 
  4988.  space available to hold the message to be written, the writev() call normally 
  4989.  blocks, unless the socket is placed in nonblocking mode. Use the select() call 
  4990.  to determine when it is possible to write more data. 
  4991.  
  4992.  Return and sock_errno() Values:  If successful, the return value is the number 
  4993.  of bytes written. Successful completion does not guarantee the data is 
  4994.  written. The return value -1 indicates an error was detected on the sending 
  4995.  side of the connection. You can get the specific error code by calling 
  4996.  sock_errno() or psock_errno(). 
  4997.  
  4998.  
  4999.            sock_errno() Value      Description 
  5000.  
  5001.       SOCECOMMSYS                  Internal communications error.  Contact IBM 
  5002.                                    Service. 
  5003.  
  5004.       SOCEDESTADDRREQ              A destination address is required. 
  5005.  
  5006.       SOCEFAULT                    Using the iov and iovcnt parameters results 
  5007.                                    in an attempt to access memory outside the 
  5008.                                    caller address space. 
  5009.  
  5010.       SOCEINVAL                    One of the parameters has an invalid value. 
  5011.  
  5012.       SOCEMSGSIZE                  The message was larger than the size of the 
  5013.                                    socket send buffer and could not be sent as 
  5014.                                    a single datagram. 
  5015.  
  5016.       SOCENOBUFS                   No buffer space is available to send the 
  5017.                                    message. 
  5018.  
  5019.       SOCENOTCONN                  The socket is not connected. 
  5020.  
  5021.       SOCENOTSOCK                  s is not a valid socket descriptor. 
  5022.  
  5023.       SOCEWOULDBLOCK               The s parameter is in nonblocking mode and 
  5024.                                    the data cannot be written without blocking, 
  5025.                                    or the SO_SNDTIMEO option has been set for 
  5026.                                    socket s and the timeout expired before any 
  5027.                                    data was sent. 
  5028.  
  5029.  
  5030. ΓòÉΓòÉΓòÉ 7. TCP/IP Network Utility Routines ΓòÉΓòÉΓòÉ
  5031.  
  5032. The following table briefly describes each sockets utility function call 
  5033. supported by MPTS and identifies the location in the book where you can find 
  5034. the syntax, parameters, and other appropriate information. The following socket 
  5035. calls described in this section can be used to access services only for the 
  5036. internet communication domain: 
  5037.  
  5038. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5039. Γöé Table 20. TCP/IP Network Utility Routines Quick Reference            Γöé
  5040. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5041. Γöé SOCKET CALL      Γöé DESCRIPTION                       Γöé
  5042. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5043. Γöé bswap()        Γöé Swaps bytes in a short integer              Γöé
  5044. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5045. Γöé dn_comp()       Γöé Compresses the expanded domain name           Γöé
  5046. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5047. Γöé dn_expand()      Γöé Expands a compressed domain name to a full domain name  Γöé
  5048. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5049. Γöé endhostent()     Γöé Closes the HOSTS file                  Γöé
  5050. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5051. Γöé endnetent()      Γöé Closes the NETWORKS file                 Γöé
  5052. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5053. Γöé endprotoent()     Γöé Closes the PROTOCOL file                 Γöé
  5054. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5055. Γöé endservent()     Γöé Closes the SERVICES file                 Γöé
  5056. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5057. Γöé gethostbyaddr()    Γöé Returns a pointer to information about a host specified Γöé
  5058. Γöé            Γöé by an internet address                  Γöé
  5059. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5060. Γöé gethostbyname()    Γöé Returns a pointer to information about a host specified Γöé
  5061. Γöé            Γöé by a host name                      Γöé
  5062. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5063. Γöé gethostent()     Γöé Returns a pointer to the next entry in the HOSTS file  Γöé
  5064. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5065. Γöé gethostid()      Γöé Returns the unique identifier of the current host    Γöé
  5066. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5067. Γöé gethostname()     Γöé Gets the standard host name for the local host machine  Γöé
  5068. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5069. Γöé getnetbyaddr()    Γöé Returns a pointer to the NETWORKS file entry that con-  Γöé
  5070. Γöé            Γöé tains the specified network address           Γöé
  5071. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5072. Γöé getnetbyname()    Γöé Returns a pointer to the NETWORKS file entry that con-  Γöé
  5073. Γöé            Γöé tains the specified network name             Γöé
  5074. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5075. Γöé getnetent()      Γöé Returns a pointer to the next entry in the NETWORKS   Γöé
  5076. Γöé            Γöé file                           Γöé
  5077. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5078. Γöé getprotobyname()   Γöé Returns a pointer to the PROTOCOL file entry specified  Γöé
  5079. Γöé            Γöé by a protocol name                    Γöé
  5080. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5081. Γöé getprotobynumber()  Γöé Returns a pointer to the PROTOCOL file entry specified  Γöé
  5082. Γöé            Γöé by a protocol number                   Γöé
  5083. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5084. Γöé getprotoent()     Γöé Returns a pointer to the next entry in the PROTOCOL   Γöé
  5085. Γöé            Γöé file                           Γöé
  5086. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5087. Γöé getservbyname()    Γöé Returns a pointer to the SERVICES file entry specified  Γöé
  5088. Γöé            Γöé by a service name                    Γöé
  5089. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5090. Γöé getservbyport()    Γöé Returns a pointer to the SERVICES file entry specified  Γöé
  5091. Γöé            Γöé by a port number                     Γöé
  5092. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5093. Γöé getservent()     Γöé Returns a pointer to the next entry in the SERVICES   Γöé
  5094. Γöé            Γöé file                           Γöé
  5095. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5096. Γöé htonl()        Γöé Translates byte order from host to network for a long  Γöé
  5097. Γöé            Γöé integer                         Γöé
  5098. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5099. Γöé htons()        Γöé Translates byte order from host to network for a short  Γöé
  5100. Γöé            Γöé integer                         Γöé
  5101. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5102. Γöé inet_addr()      Γöé Constructs an internet address from character strings  Γöé
  5103. Γöé            Γöé representing numbers expressed in standard dotted-    Γöé
  5104. Γöé            Γöé decimal notation                     Γöé
  5105. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5106. Γöé inet_lnaof()     Γöé Returns the local network portion of an internet     Γöé
  5107. Γöé            Γöé address                         Γöé
  5108. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5109. Γöé inet_makeaddr()    Γöé Constructs an internet address from a network number   Γöé
  5110. Γöé            Γöé and a local address                   Γöé
  5111. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5112. Γöé inet_netof()     Γöé Returns the network portion of the internet address in  Γöé
  5113. Γöé            Γöé network-byte order                    Γöé
  5114. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5115. Γöé inet_network()    Γöé Constructs a network number from character strings    Γöé
  5116. Γöé            Γöé representing numbers expressed in standard dotted-    Γöé
  5117. Γöé            Γöé decimal notation                     Γöé
  5118. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5119. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5120. Γöé Table 20. TCP/IP Network Utility Routines Quick Reference            Γöé
  5121. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5122. Γöé SOCKET CALL      Γöé DESCRIPTION                       Γöé
  5123. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5124. Γöé inet_ntoa()      Γöé Returns a pointer to a string in dotted-decimal nota-  Γöé
  5125. Γöé            Γöé tion                           Γöé
  5126. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5127. Γöé lswap()        Γöé Swaps bytes in a long integer              Γöé
  5128. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5129. Γöé ntohl()        Γöé Translates byte order from network to host for a long  Γöé
  5130. Γöé            Γöé integer                         Γöé
  5131. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5132. Γöé ntohs()        Γöé Translates byte order from network to host for a short  Γöé
  5133. Γöé            Γöé integer                         Γöé
  5134. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5135. Γöé res_init()      Γöé Reads the RESOLV file for the default domain name    Γöé
  5136. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5137. Γöé res_mkquery()     Γöé Makes query message for the name servers in the     Γöé
  5138. Γöé            Γöé internet domain                     Γöé
  5139. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5140. Γöé res_send()      Γöé Sends query to a local name server            Γöé
  5141. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5142. Γöé sethostent()     Γöé Opens and rewinds the HOSTS file             Γöé
  5143. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5144. Γöé setnetent()      Γöé Opens and rewinds the NETWORKS file           Γöé
  5145. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5146. Γöé setprotoent()     Γöé Opens and rewinds the PROTOCOL file           Γöé
  5147. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5148. Γöé setservent()     Γöé Opens and rewinds the SERVICES file           Γöé
  5149. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5150.  
  5151.  
  5152. ΓòÉΓòÉΓòÉ 7.1. bswap() ΓòÉΓòÉΓòÉ
  5153.  
  5154. Swaps bytes in a short integer. 
  5155.  
  5156. #include <types.h>
  5157. #include <utils.h>
  5158.  
  5159. u_short bswap(a)
  5160. u_short a;
  5161.  
  5162.  Parameter      Description 
  5163.  
  5164.  a              Unsigned short integer whose bytes are to be swapped 
  5165.  
  5166.  Description:  This call swaps bytes in a short integer. 
  5167.  
  5168.  Return Value:  Returns the translated short integer. 
  5169.  
  5170.  
  5171. ΓòÉΓòÉΓòÉ 7.2. dn_comp() ΓòÉΓòÉΓòÉ
  5172.  
  5173. Compresses the expanded domain name. 
  5174.  
  5175. #include <types.h>
  5176. #include <netinet\in.h>
  5177. #include <arpa\nameser.h>
  5178. #include <resolv.h>
  5179.  
  5180. int dn_comp(exp_dn, comp_dn, length, dnptrs, lastdnptr)
  5181. u_char *exp_dn;
  5182. u_char *comp_dn;
  5183. int length;
  5184. u_char **dnptrs;
  5185. u_char **lastdnptr;
  5186.  
  5187.  Parameter      Description 
  5188.  
  5189.  exp_dn         Pointer to the location of an expanded domain name 
  5190.  
  5191.  comp_dn        Pointer to an array containing the compressed domain name 
  5192.  
  5193.  length         Length of the array in bytes pointed to by the comp_dn 
  5194.                 parameter 
  5195.  
  5196.  dnptrs         List of pointers to previously compressed names in the current 
  5197.                 message 
  5198.  
  5199.  lastdnptr      Pointer to the end of the array pointed to by dnptrs 
  5200.  
  5201.  Description:  This call compresses the domain name pointed to by the exp_dn 
  5202.  parameter and stores it in the area pointed to by the comp_dn parameter. It 
  5203.  uses the global _res structure, which is defined in the <RESOLV.H> header 
  5204.  file. 
  5205.  
  5206.  Return Value:  When successful, the dn_comp()  call returns the size of the 
  5207.  compressed domain name. If it fails, the call returns a value of -1. 
  5208.  
  5209.  
  5210. ΓòÉΓòÉΓòÉ 7.3. dn_expand() ΓòÉΓòÉΓòÉ
  5211.  
  5212. Expands a compressed domain name to a full domain name. 
  5213.  
  5214. #include <types.h>
  5215. #include <netinet\in.h>
  5216. #include <arpa\nameser.h>
  5217. #include <resolv.h>
  5218.  
  5219. int dn_expand(msg, eomorig, comp_dn, exp_dn, length)
  5220. u_char *msg;
  5221. u_char *eomorig;
  5222. u_char *comp_dn;
  5223. u_char *exp_dn;
  5224. int length;
  5225.  
  5226.  Parameter      Description 
  5227.  
  5228.  msg            Pointer to the beginning of a message 
  5229.  
  5230.  eomorig        Pointer to the end of the original message that contains the 
  5231.                 compressed domain name 
  5232.  
  5233.  comp_dn        Pointer to the compressed domain name 
  5234.  
  5235.  exp_dn         Pointer to a buffer that holds the resulting expanded domain 
  5236.                 name 
  5237.  
  5238.  length         Length of the buffer in bytes pointed to by the exp_dn 
  5239.                 parameter 
  5240.  
  5241.  Description:  This call expands a compressed domain name to a full domain 
  5242.  name, converting the expanded name to all uppercase letters. It uses the 
  5243.  global _res structure, which is defined in the <RESOLV.H> header file. 
  5244.  
  5245.  Return Value:  If it succeeds, the dn_expand() call returns the size of the 
  5246.  expanded domain name. If it fails, the call returns a value of -1. 
  5247.  
  5248.  
  5249. ΓòÉΓòÉΓòÉ 7.4. endhostent() ΓòÉΓòÉΓòÉ
  5250.  
  5251. Closes the HOSTS file. 
  5252.  
  5253. void endhostent()
  5254.  
  5255. Description: This call closes the ETC\HOSTS file, which contains information 
  5256. about known hosts. 
  5257.  
  5258.  
  5259. ΓòÉΓòÉΓòÉ 7.5. endnetent() ΓòÉΓòÉΓòÉ
  5260.  
  5261. Closes the NETWORKS file. 
  5262.  
  5263. void endnetent()
  5264.  
  5265. Description:  The endnetent() call closes the ETC\NETWORKS file, which contains 
  5266. information about known networks. 
  5267.  
  5268.  
  5269. ΓòÉΓòÉΓòÉ 7.6. endprotoent() ΓòÉΓòÉΓòÉ
  5270.  
  5271. Closes the PROTOCOL file. 
  5272.  
  5273. void endprotoent()
  5274.  
  5275. Description:  This call closes the ETC\PROTOCOL file, which contains 
  5276. information about known protocols. 
  5277.  
  5278.  
  5279. ΓòÉΓòÉΓòÉ 7.7. endservent() ΓòÉΓòÉΓòÉ
  5280.  
  5281. Closes the SERVICES file. 
  5282.  
  5283. void endservent()
  5284.  
  5285. Description:  This call closes the ETC\SERVICES file, which contains 
  5286. information about known services. 
  5287.  
  5288.  
  5289. ΓòÉΓòÉΓòÉ 7.8. gethostbyaddr() ΓòÉΓòÉΓòÉ
  5290.  
  5291. Returns a pointer to information about a host specified by an internet address. 
  5292.  
  5293. #include <netdb.h>
  5294.  
  5295. struct hostent *gethostbyaddr(addr, addrlen, addrfam)
  5296. char *addr;
  5297. int addrlen;
  5298. int addrfam;
  5299.  
  5300.  Parameter      Description 
  5301.  
  5302.  addr           Pointer to a 32-bit internet address in network-byte order 
  5303.  
  5304.  addrlen        Size of addr in bytes 
  5305.  
  5306.  addrfam        Address family supported (AF_INET) 
  5307.  
  5308.  Description:  This call resolves the host name through a name server, if one 
  5309.  is present. If a name server is not present or cannot resolve the host name, 
  5310.  gethostbyaddr() searches the ETC\HOSTS file in sequence until a matching host 
  5311.  address is found or an end-of-file (EOF) marker is reached. 
  5312.  
  5313.  Return Value:  The return value points to static data that subsequent API 
  5314.  calls can modify. This call returns a pointer to a hostent structure for the 
  5315.  host address specified on the call and indicates success. A NULL pointer 
  5316.  indicates an error or EOF. 
  5317.  
  5318.  The <NETDB.H> header file defines the hostent structure and contains the 
  5319.  following elements: 
  5320.  
  5321.  
  5322.            Element     Description 
  5323.       h_name           Official name of the host 
  5324.       h_aliases        Zero-terminated array of alternative names for the host 
  5325.       h_addrtype       The address family of the network address being 
  5326.                        returned, always set to AF_INET 
  5327.       h_length         Length of the address in bytes 
  5328.       h_addr           Pointer to the network address of the host 
  5329.  
  5330.  The value of h_errno indicates the specific error. 
  5331.  
  5332.    ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5333.    Γöé H_ERRNO VALUE  Γöé CODE  Γöé DESCRIPTION                  Γöé
  5334.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5335.    Γöé HOST_NOT_FOUND  Γöé  1   Γöé The host specified by the addr parameter is  Γöé
  5336.    Γöé         Γöé    Γöé not found.                   Γöé
  5337.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5338.    Γöé TRY_AGAIN    Γöé  2   Γöé The local server does not receive a response  Γöé
  5339.    Γöé         Γöé    Γöé from an authorized server.  Try again later.  Γöé
  5340.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5341.    Γöé NO_RECOVERY   Γöé  3   Γöé This error code indicates an unrecoverable   Γöé
  5342.    Γöé         Γöé    Γöé error.                     Γöé
  5343.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5344.    Γöé NO_DATA     Γöé  4   Γöé The requested addr is valid, but does not   Γöé
  5345.    Γöé         Γöé    Γöé have an internet address at the name server.  Γöé
  5346.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5347.    Γöé NO_ADDRESS    Γöé  4   Γöé The requested addr is valid, but does not   Γöé
  5348.    Γöé         Γöé    Γöé have an internet address at the name server.  Γöé
  5349.    ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5350.  
  5351.  
  5352. ΓòÉΓòÉΓòÉ 7.9. gethostbyname() ΓòÉΓòÉΓòÉ
  5353.  
  5354. Returns a pointer to information about a host specified by a host name. 
  5355.  
  5356. #include <netdb.h>
  5357.  
  5358. struct hostent *gethostbyname(name)
  5359. char *name;
  5360.  
  5361.  Parameter      Description 
  5362.  
  5363.  name           Pointer to the name of the host being queried 
  5364.  
  5365.  Description:  This call resolves the host name through a name server, if one 
  5366.  is present. If a name server is not present or is unable to resolve the host 
  5367.  name, gethostbyname() searches the ETC\HOSTS file in sequence until a matching 
  5368.  host name is found or an EOF marker is reached. 
  5369.  
  5370.  Return Value and h_errno Value:  The return value points to static data that 
  5371.  subsequent API calls can modify. This call returns a pointer to a hostent 
  5372.  structure for the host address specified on the call and indicates success. A 
  5373.  NULL pointer indicates an error or EOF. 
  5374.  
  5375.  The <NETDB.H> header file defines the hostent structure and contains the 
  5376.  following elements: 
  5377.  
  5378.  
  5379.            Element     Description 
  5380.       h_name           Official name of the host 
  5381.       h_aliases        Zero-terminated array of alternative names for the host 
  5382.       h_addrtype       The address family of the network address being 
  5383.                        returned, always set to AF_INET 
  5384.       h_length         Length of the address in bytes 
  5385.       h_addr           Pointer to the network address of the host 
  5386.  
  5387.  The value of h_errno indicates the specific error. 
  5388.  
  5389.    ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5390.    Γöé H_ERRNO VALUE  Γöé CODE  Γöé DESCRIPTION                  Γöé
  5391.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5392.    Γöé HOST_NOT_FOUND  Γöé  1   Γöé The host specified by the name parameter is  Γöé
  5393.    Γöé         Γöé    Γöé not found.                   Γöé
  5394.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5395.    Γöé TRY_AGAIN    Γöé  2   Γöé The local server does not receive a response  Γöé
  5396.    Γöé         Γöé    Γöé from an authorized server.  Try again later.  Γöé
  5397.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5398.    Γöé NO_RECOVERY   Γöé  3   Γöé This error code indicates an unrecoverable   Γöé
  5399.    Γöé         Γöé    Γöé error.                     Γöé
  5400.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5401.    Γöé NO_DATA     Γöé  4   Γöé The requested name is valid, but does not   Γöé
  5402.    Γöé         Γöé    Γöé have an internet address at the name server.  Γöé
  5403.    Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5404.    Γöé NO_ADDRESS    Γöé  4   Γöé The requested name is valid, but does not   Γöé
  5405.    Γöé         Γöé    Γöé have an internet address at the name server.  Γöé
  5406.    ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5407.  
  5408.  
  5409. ΓòÉΓòÉΓòÉ 7.10. gethostent() ΓòÉΓòÉΓòÉ
  5410.  
  5411. Returns a pointer to the next entry in the HOSTS file. 
  5412.  
  5413. #include <manifest.h>
  5414. #include <netdb.h>
  5415.  
  5416. struct hostent *gethostent()
  5417.  
  5418. Description: This call returns a pointer to the next entry in the HOSTS file. 
  5419.  
  5420. Return Value:  The return value points to static data that subsequent API calls 
  5421. can modify. This call returns a pointer to a hostent structure for the host 
  5422. address specified on the call and indicates success. A NULL pointer indicates 
  5423. an error or EOF. 
  5424.  
  5425. The <NETDB.H> header file defines the hostent structure and contains the 
  5426. following elements: 
  5427.  
  5428.  
  5429.            Element     Description 
  5430.       h_name           Official name of the host 
  5431.       h_aliases        Zero-terminated array of alternative names for the host 
  5432.       h_addrtype       The address family of the network address being 
  5433.                        returned, always set to AF_INET 
  5434.       h_length         Length of the address in bytes 
  5435.       h_addr           Pointer to the network address of the host 
  5436.  
  5437.  
  5438. ΓòÉΓòÉΓòÉ 7.11. gethostid() ΓòÉΓòÉΓòÉ
  5439.  
  5440. Returns the unique identifier of the current host. 
  5441.  
  5442. #include <types.h>
  5443.  
  5444. u_long gethostid()
  5445.  
  5446. Description:  This call gets the unique 32-bit identifier in network-byte order 
  5447. for the current host. 
  5448.  
  5449. Return Value:  The gethostid() call returns the 32-bit identifier, in 
  5450. network-byte order of the current host, which should be unique across all 
  5451. hosts. 
  5452.  
  5453.  
  5454. ΓòÉΓòÉΓòÉ 7.12. gethostname() ΓòÉΓòÉΓòÉ
  5455.  
  5456. Gets the standard host name for the local host machine. 
  5457.  
  5458. #include <netdb.h>
  5459.  
  5460. int gethostname(name, namelen)
  5461. char *name;
  5462. int namelen;
  5463.  
  5464.  Parameter      Description 
  5465.  
  5466.  name           Pointer to a buffer 
  5467.  
  5468.  namelen        Length of the buffer 
  5469.  
  5470.  Description:  This call copies the standard host name for the local host into 
  5471.  the buffer specified by the name parameter. The returned name is a 
  5472.  null-terminated string. 
  5473.  
  5474.  Return Value:  The value 0 indicates success; the value -1 indicates an error. 
  5475.  
  5476.  
  5477. ΓòÉΓòÉΓòÉ 7.13. getnetbyaddr() ΓòÉΓòÉΓòÉ
  5478.  
  5479. Returns a pointer to the NETWORKS file entry that contains the specified 
  5480. network address. 
  5481.  
  5482. #include <netdb.h>
  5483.  
  5484. struct netent *getnetbyaddr(net, type)
  5485. u_long net;
  5486. int type;
  5487.  
  5488.  Parameter      Description 
  5489.  
  5490.  net            Network address 
  5491.  
  5492.  type           Address family supported (AF_INET) 
  5493.  
  5494.  Description:  The getnetbyaddr() call searches the ETC\NETWORKS file for the 
  5495.  specified network address. 
  5496.  
  5497.  Return Value:  The return value points to static data that subsequent API 
  5498.  calls can modify.  A pointer to a netent structure indicates success.  A NULL 
  5499.  pointer indicates an error or EOF. 
  5500.  
  5501.  The netent structure is defined in the <NETDB.H> header file and contains the 
  5502.  following elements: 
  5503.  
  5504.  
  5505.            Element     Description 
  5506.  
  5507.       n_name           Official name of the network 
  5508.  
  5509.       n_aliases        An array, terminated with a NULL pointer, of alternative 
  5510.                        names for the network 
  5511.  
  5512.       n_addrtype       The address family of the network address being 
  5513.                        returned, always set to AF_INET 
  5514.  
  5515.       n_net            Network number, returned in host-byte order 
  5516.  
  5517.  
  5518. ΓòÉΓòÉΓòÉ 7.14. getnetbyname() ΓòÉΓòÉΓòÉ
  5519.  
  5520. Returns a pointer to the NETWORKS file entry that contains the specified 
  5521. network name. 
  5522.  
  5523. #include <netdb.h>
  5524.  
  5525. struct netent *getnetbyname(name)
  5526. char *name;
  5527.  
  5528.  Parameter      Description 
  5529.  
  5530.  name           Pointer to a network name 
  5531.  
  5532.  Description:  This call searches the ETC\NETWORKS file for the specified 
  5533.  network name. 
  5534.  
  5535.  Return Value:  The getnetbyname() call returns a pointer to a netent structure 
  5536.  for the network name specified on the call. The return value points to static 
  5537.  data that subsequent API calls can modify.  A pointer to a netent structure 
  5538.  indicates success.  A NULL pointer indicates an error or EOF. 
  5539.  
  5540.  The netent structure is defined in the <NETDB.H> header file and contains the 
  5541.  following elements: 
  5542.  
  5543.  
  5544.            Element     Description 
  5545.  
  5546.       n_name           Official name of the network 
  5547.  
  5548.       n_aliases        An array, terminated with a NULL pointer, of alternative 
  5549.                        names for the network 
  5550.  
  5551.       n_addrtype       The address family of the network address being 
  5552.                        returned, always set to AF_INET 
  5553.  
  5554.       n_net            Network number, returned in host-byte order 
  5555.  
  5556.  
  5557. ΓòÉΓòÉΓòÉ 7.15. getnetent() ΓòÉΓòÉΓòÉ
  5558.  
  5559. Returns a pointer to the next entry in the NETWORKS file. 
  5560.  
  5561. #include <netdb.h>
  5562.  
  5563. struct netent *getnetent()
  5564.  
  5565. Description:  This call returns a pointer to the next entry in the ETC\NETWORKS 
  5566. file. 
  5567.  
  5568. Return Value:  The getnetent() call returns a pointer to the next entry in the 
  5569. ETC\NETWORKS file. The return value points to static data that subsequent API 
  5570. calls can modify. A pointer to a netent structure indicates success. A NULL 
  5571. pointer indicates an error or EOF. 
  5572.  
  5573. The netent structure is defined in the <NETDB.H> header file and contains the 
  5574. following elements: 
  5575.  
  5576.  
  5577.            Element     Description 
  5578.  
  5579.       n_name           Official name of the network 
  5580.  
  5581.       n_aliases        An array, terminated with a NULL pointer, of alternative 
  5582.                        names for the network 
  5583.  
  5584.       n_addrtype       The address family of the network address being 
  5585.                        returned, always set to AF_INET 
  5586.  
  5587.       n_net            Network number, returned in host-byte order 
  5588.  
  5589.  
  5590. ΓòÉΓòÉΓòÉ 7.16. getprotobyname() ΓòÉΓòÉΓòÉ
  5591.  
  5592. Returns a pointer to the PROTOCOL file entry specified by a protocol name. 
  5593.  
  5594. #include <netdb.h>
  5595.  
  5596. struct protoent *getprotobyname(name)
  5597. char *name;
  5598.  
  5599.  Parameter      Description 
  5600.  
  5601.  name           Pointer to the specified protocol 
  5602.  
  5603.  Description:  This call searches the ETC\PROTOCOL file for the specified 
  5604.  protocol name. 
  5605.  
  5606.  Return Value:  The getprotobyname() call returns a pointer to a protoent 
  5607.  structure for the network protocol specified on the call. The return value 
  5608.  points to static data that subsequent API calls can modify. A pointer to a 
  5609.  protoent structure indicates success. A NULL pointer indicates an error or 
  5610.  EOF. 
  5611.  
  5612.  The protoent structure is defined in the <NETDB.H> header file and contains 
  5613.  the following elements: 
  5614.  
  5615.  
  5616.            Element     Description 
  5617.  
  5618.       p_name           Official name of the protocol 
  5619.  
  5620.       p_aliases        Array, terminated with a NULL pointer, of alternative 
  5621.                        names for the protocol 
  5622.  
  5623.       p_proto          Protocol number 
  5624.  
  5625.  
  5626. ΓòÉΓòÉΓòÉ 7.17. getprotobynumber() ΓòÉΓòÉΓòÉ
  5627.  
  5628. Returns a pointer to the PROTOCOL file entry specified by a protocol number. 
  5629.  
  5630. #include <netdb.h>
  5631.  
  5632. struct protoent * getprotobynumber(proto)
  5633. int proto;
  5634.  
  5635.  Parameter      Description 
  5636.  
  5637.  proto          Protocol number 
  5638.  
  5639.  Description:  This call searches the ETC\PROTOCOL file for the specified 
  5640.  protocol number. 
  5641.  
  5642.  Return Value:  The getprotobynumber() call returns a pointer to a protoent 
  5643.  structure for the network protocol specified on the call. The return value 
  5644.  points to static data that subsequent API calls can modify. A pointer to a 
  5645.  protoent structure indicates success. A NULL pointer indicates an error or 
  5646.  EOF. 
  5647.  
  5648.  The protoent structure is defined in the <NETDB.H> header file and contains 
  5649.  the following elements: 
  5650.  
  5651.  
  5652.            Element     Description 
  5653.  
  5654.       p_name           Official name of the protocol 
  5655.  
  5656.       p_aliases        Array, terminated with a NULL pointer, of alternative 
  5657.                        names for the protocol 
  5658.  
  5659.       p_proto          Protocol number 
  5660.  
  5661.  
  5662. ΓòÉΓòÉΓòÉ 7.18. getprotoent() ΓòÉΓòÉΓòÉ
  5663.  
  5664. Returns a pointer to the next entry in the PROTOCOL file. 
  5665.  
  5666. #include <netdb.h>
  5667.  
  5668. struct protoent *getprotoent()
  5669.  
  5670. Description:  This call searches for the next entry in the ETC\PROTOCOL file. 
  5671.  
  5672. Return Value:  The getprotoent() call returns a pointer to the next entry in 
  5673. the file, ETC\PROTOCOL. The return value points to static data that subsequent 
  5674. API calls can modify. A pointer to a protoent structure indicates success. A 
  5675. NULL pointer indicates an error or EOF. 
  5676.  
  5677. The protoent structure is defined in the <NETDB.H> header file and contains the 
  5678. following elements: 
  5679.  
  5680.  
  5681.            Element     Description 
  5682.  
  5683.       p_name           Official name of the protocol 
  5684.  
  5685.       p_aliases        Array, terminated with a NULL pointer, of alternative 
  5686.                        names for the protocol 
  5687.  
  5688.       p_proto          Protocol number 
  5689.  
  5690.  
  5691. ΓòÉΓòÉΓòÉ 7.19. getservbyname() ΓòÉΓòÉΓòÉ
  5692.  
  5693. Returns a pointer to the SERVICES file entry specified by a service name. 
  5694.  
  5695. #include <netdb.h>
  5696.  
  5697. struct servent *getservbyname(name, proto)
  5698. char *name;
  5699. char *proto;
  5700.  
  5701.  Parameter      Description 
  5702.  
  5703.  name           Pointer to the service name 
  5704.  
  5705.  proto          Pointer to the specified protocol 
  5706.  
  5707.  Description:  This call searches the ETC\SERVICES file for the specified 
  5708.  service name, which must match the protocol if a protocol is stated. 
  5709.  
  5710.  Return Value:  The call returns a pointer to a servent structure for the 
  5711.  network service specified on the call. The return value points to static data 
  5712.  that subsequent API calls can modify. A pointer to a servent structure 
  5713.  indicates success. A NULL pointer indicates an error or EOF. 
  5714.  
  5715.  The servent structure is defined in the <NETDB.H> header file and contains the 
  5716.  following elements: 
  5717.  
  5718.  
  5719.            Element     Description 
  5720.  
  5721.       s_name           Official name of the service 
  5722.  
  5723.       s_aliases        Array, terminated with a NULL pointer, of alternative 
  5724.                        names for the service 
  5725.  
  5726.       s_port           Port number of the service 
  5727.  
  5728.       s_proto          Required protocol to contact the service 
  5729.  
  5730.  
  5731. ΓòÉΓòÉΓòÉ 7.20. getservbyport() ΓòÉΓòÉΓòÉ
  5732.  
  5733. Returns a pointer to the SERVICES file entry specified by a port number. 
  5734.  
  5735. #include <netdb.h>
  5736.  
  5737. struct servent *getservbyport(port, proto)
  5738. int port;
  5739. char *proto;
  5740.  
  5741.  Parameter      Description 
  5742.  
  5743.  port           Specified port 
  5744.  
  5745.  proto          Pointer to the specified protocol 
  5746.  
  5747.  Description:  This call sequentially searches the ETC\SERVICES file for the 
  5748.  specified port number, which must match the protocol if a protocol is stated. 
  5749.  
  5750.  Return Value:  The getservbyport() call returns a pointer to a servent 
  5751.  structure for the port number specified on the call. The return value points 
  5752.  to static data that subsequent API calls can modify. A pointer to a servent 
  5753.  structure indicates success. A NULL pointer indicates an error or EOF. 
  5754.  
  5755.  The servent structure is defined in the <NETDB.H> header file and contains the 
  5756.  following elements: 
  5757.  
  5758.  
  5759.            Element     Description 
  5760.  
  5761.       s_name           Official name of the service 
  5762.  
  5763.       s_aliases        Array, terminated with a NULL pointer, of alternative 
  5764.                        names for the service 
  5765.  
  5766.       s_port           Port number of the service 
  5767.  
  5768.       s_proto          Required protocol to contact the service 
  5769.  
  5770.  
  5771. ΓòÉΓòÉΓòÉ 7.21. getservent() ΓòÉΓòÉΓòÉ
  5772.  
  5773. Returns a pointer to the next entry in the SERVICES file. 
  5774.  
  5775. #include <netdb.h>
  5776.  
  5777. struct servent *getservent()
  5778.  
  5779. Description:  This call searches for the next line in the ETC\SERVICES file. 
  5780.  
  5781. Return Value:  The getservent() call returns a pointer to the next entry in the 
  5782. ETC\SERVICES file. The return value points to static data that subsequent API 
  5783. calls can modify. A pointer to a servent structure indicates success. A NULL 
  5784. pointer indicates an error or EOF. 
  5785.  
  5786. The servent structure is defined in the <NETDB.H> header file and contains the 
  5787. following elements: 
  5788.  
  5789.  
  5790.            Element     Description 
  5791.  
  5792.       s_name           Official name of the service 
  5793.  
  5794.       s_aliases        Array, terminated with a NULL pointer, of alternative 
  5795.                        names for the service 
  5796.  
  5797.       s_port           Port number of the service 
  5798.  
  5799.       s_proto          Required protocol to contact the service 
  5800.  
  5801.  
  5802. ΓòÉΓòÉΓòÉ 7.22. htonl() ΓòÉΓòÉΓòÉ
  5803.  
  5804. Translates a long integer from host-byte order to network-byte order. 
  5805.  
  5806. #include <types.h>
  5807. #include <utils.h>
  5808.  
  5809. u_long htonl(a)
  5810. u_long a;
  5811.  
  5812.  Parameter      Description 
  5813.  
  5814.  a              Unsigned long integer to be put into network-byte order 
  5815.  
  5816.  Description:  This call translates a long integer from host-byte order to 
  5817.  network-byte order. 
  5818.  
  5819.  Return Value:  Returns the translated long integer. 
  5820.  
  5821.  
  5822. ΓòÉΓòÉΓòÉ 7.23. htons() ΓòÉΓòÉΓòÉ
  5823.  
  5824. Translates a short integer from host-byte order to network-byte order. 
  5825.  
  5826. #include <types.h>
  5827. #include <utils.h>
  5828.  
  5829. u_short htons(a)
  5830. u_short a;
  5831.  
  5832.  Parameter      Description 
  5833.  
  5834.  a              Unsigned short integer to be put into network-byte order 
  5835.  
  5836.  Description:  This call translates a short integer from host-byte order to 
  5837.  network-byte order. 
  5838.  
  5839.  Return Value:  Returns the translated short integer. 
  5840.  
  5841.  
  5842. ΓòÉΓòÉΓòÉ 7.24. inet_addr() ΓòÉΓòÉΓòÉ
  5843.  
  5844. Constructs an internet address from character strings representing numbers 
  5845. expressed in standard dotted-decimal notation. 
  5846.  
  5847. #include <types.h>
  5848.  
  5849. u_long inet_addr(cp)
  5850. char *cp;
  5851.  
  5852.  Parameter      Description 
  5853.  
  5854.  cp             A character string in standard dotted-decimal notation 
  5855.  
  5856.  Description:  This call interprets character strings representing numbers 
  5857.  expressed in standard dotted-decimal notation and returns numbers suitable for 
  5858.  use as an internet address. 
  5859.  
  5860.  Values specified in standard dotted-decimal notation take one of the following 
  5861.  forms: 
  5862.  
  5863.   a.b.c.d
  5864.   a.b.c
  5865.   a.b
  5866.   a
  5867.  
  5868.  When a four-part address is specified, each part is interpreted as a byte of 
  5869.  data and assigned, from left to right, to one of the 4 bytes of an internet 
  5870.  address. 
  5871.  
  5872.  When a three-part address is specified, the last part is interpreted as a 
  5873.  16-bit quantity and placed in the two rightmost bytes of the network address. 
  5874.  This makes the three-part address format convenient for specifying Class B 
  5875.  network addresses as 128.net.host. 
  5876.  
  5877.  When a two-part address is specified, the last part is interpreted as a 24-bit 
  5878.  quantity and placed in the three rightmost bytes of the network address. This 
  5879.  makes the two-part address format convenient for specifying Class A network 
  5880.  addresses as net.host. 
  5881.  
  5882.  When a one-part address is specified, the value is stored directly in the 
  5883.  network address space without any rearrangement of its bytes. 
  5884.  
  5885.  Numbers supplied as address parts in standard dotted-decimal notation can be 
  5886.  decimal, hexadecimal, or octal. Numbers are interpreted in C language syntax. 
  5887.  A leading 0x implies hexadecimal; a leading 0 implies octal. A number without 
  5888.  a leading 0 implies decimal. 
  5889.  
  5890.  Return Value:  The internet address is returned in network-byte order. 
  5891.  
  5892.  
  5893. ΓòÉΓòÉΓòÉ 7.25. inet_lnaof() ΓòÉΓòÉΓòÉ
  5894.  
  5895. Returns the local network portion of an internet address. 
  5896.  
  5897. #include <types.h>
  5898. #include <netinet\in.h>
  5899.  
  5900. u_long inet_lnaof(in)
  5901. struct in_addr in;
  5902.  
  5903.  Parameter      Description 
  5904.  
  5905.  in             Host internet address 
  5906.  
  5907.  Description:  This call breaks apart the internet host address and returns the 
  5908.  local network address portion. 
  5909.  
  5910.  Return Value:  The local network address is returned in host-byte order. 
  5911.  
  5912.  
  5913. ΓòÉΓòÉΓòÉ 7.26. inet_makeaddr() ΓòÉΓòÉΓòÉ
  5914.  
  5915. Constructs an internet address from a network number and a local address. 
  5916.  
  5917. #include <types.h>
  5918. #include <netinet\in.h>
  5919.  
  5920. struct in_addr inet_makeaddr(net, lna)
  5921. u_long net;
  5922. u_long lna;
  5923.  
  5924.  Parameter      Description 
  5925.  
  5926.  net            Network number 
  5927.  
  5928.  lna            Local network address 
  5929.  
  5930.  Description:  This call takes a network number and a local network address and 
  5931.  constructs an internet address. 
  5932.  
  5933.  Return Value:  The internet address is returned in network-byte order. 
  5934.  
  5935.  
  5936. ΓòÉΓòÉΓòÉ 7.27. inet_netof() ΓòÉΓòÉΓòÉ
  5937.  
  5938. Returns the network portion of the internet host address in network-byte order. 
  5939.  
  5940. #include <types.h>
  5941. #include <netinet\in.h>
  5942.  
  5943. u_long inet_netof(in)
  5944. struct in_addr in;
  5945.  
  5946.  Parameter      Description 
  5947.  
  5948.  in             Internet address in network-byte order 
  5949.  
  5950.  Description:  This call breaks apart the internet host address and returns the 
  5951.  network number portion. 
  5952.  
  5953.  Return Value:  The network number is returned in host-byte order. 
  5954.  
  5955.  
  5956. ΓòÉΓòÉΓòÉ 7.28. inet_network() ΓòÉΓòÉΓòÉ
  5957.  
  5958. Constructs a network number from character strings representing numbers 
  5959. expressed in standard dotted-decimal notation. 
  5960.  
  5961. #include <types.h>
  5962.  
  5963. u_long inet_network(cp)
  5964. char *cp;
  5965.  
  5966.  Parameter      Description 
  5967.  
  5968.  cp             A character string in standard dotted-decimal notation 
  5969.  
  5970.  Description:  This call interprets character strings representing numbers 
  5971.  expressed in standard dotted-decimal notation and returns numbers suitable for 
  5972.  use as a network number. 
  5973.  
  5974.  Return Value:  The network number is returned in host-byte order. 
  5975.  
  5976.  
  5977. ΓòÉΓòÉΓòÉ 7.29. inet_ntoa() ΓòÉΓòÉΓòÉ
  5978.  
  5979. Returns a pointer to a string in dotted-decimal notation. 
  5980.  
  5981. #include <types.h>
  5982. #include <netinet\in.h>
  5983.  
  5984. char *inet_ntoa(in)
  5985. struct in_addr in;
  5986.  
  5987.  Parameter      Description 
  5988.  
  5989.  in             Host internet address 
  5990.  
  5991.  Description:  This call returns a pointer to a string expressed in the 
  5992.  dotted-decimal notation. The inet_ntoa() call accepts an internet address 
  5993.  expressed as a 32-bit quantity in network-byte order and returns a string 
  5994.  expressed in dotted-decimal notation. 
  5995.  
  5996.  Return Value:  Returns a pointer to the internet address expressed in 
  5997.  dotted-decimal notation. 
  5998.  
  5999.  
  6000. ΓòÉΓòÉΓòÉ 7.30. lswap() ΓòÉΓòÉΓòÉ
  6001.  
  6002. Swaps bytes in a long integer. 
  6003.  
  6004. #include <types.h>
  6005. #include <utils.h>
  6006.  
  6007. u_long lswap(a)
  6008. u_long a;
  6009.  
  6010.  Parameter      Description 
  6011.  
  6012.  a              Unsigned long integer whose bytes are to be swapped 
  6013.  
  6014.  Description:  This call swaps bytes in a long integer. 
  6015.  
  6016.  Return Value:  Returns the translated long integer. 
  6017.  
  6018.  
  6019. ΓòÉΓòÉΓòÉ 7.31. ntohl() ΓòÉΓòÉΓòÉ
  6020.  
  6021. Translates a long integer from network-byte order to host-byte order. 
  6022.  
  6023. #include <types.h>
  6024. #include <utils.h>
  6025.  
  6026. u_long ntohl(a)
  6027. u_long a;
  6028.  
  6029.  Parameter      Description 
  6030.  
  6031.  a              Unsigned long integer to be put into host-byte order 
  6032.  
  6033.  Description:  This call translates a long integer from network-byte order to 
  6034.  host-byte order. 
  6035.  
  6036.  Return Value:  Returns the translated long integer. 
  6037.  
  6038.  
  6039. ΓòÉΓòÉΓòÉ 7.32. ntohs() ΓòÉΓòÉΓòÉ
  6040.  
  6041. Translates a short integer from network-byte order to host-byte order. 
  6042.  
  6043. #include <types.h>
  6044. #include <utils.h>
  6045.  
  6046. u_short ntohs(a)
  6047. u_short a;
  6048.  
  6049.  Parameter      Description 
  6050.  
  6051.  a              Unsigned short integer to be put into host-byte order 
  6052.  Description:  This call translates a short integer from network-byte order to 
  6053.  host-byte order. 
  6054.  
  6055.  Return Value:  The ntohs() call returns the translated short integer. 
  6056.  
  6057.  
  6058. ΓòÉΓòÉΓòÉ 7.33. res_init() ΓòÉΓòÉΓòÉ
  6059.  
  6060. Reads the RESOLV file for the default domain name. 
  6061.  
  6062. #include <types.h>
  6063. #include <netinet\in.h>
  6064. #include <arpa\nameser.h>
  6065. #include <resolv.h>
  6066.  
  6067. void res_init()
  6068.  
  6069. Description:  This call reads the ETC\RESOLV file for the default domain name 
  6070. and for the internet address of the initial hosts running the name server. If 
  6071. that file does not exist, the call attempts name resolution using the ETC\HOSTS 
  6072. file. One of these files should be operational. 
  6073.  
  6074. The call stores domain name information in the global _res structure, which is 
  6075. defined in the <RESOLV.H> header file. 
  6076.  
  6077.  
  6078. ΓòÉΓòÉΓòÉ 7.34. res_mkquery() ΓòÉΓòÉΓòÉ
  6079.  
  6080. Makes a query message for the name servers in the internet domain. 
  6081.  
  6082. #include <types.h>
  6083. #include <netinet\in.h>
  6084. #include <arpa\nameser.h>
  6085. #include <resolv.h>
  6086.  
  6087. int res_mkquery (op, dname, class, type, data, datalen, newrr, buf, buflen)
  6088. int op;
  6089. char *dname;
  6090. int class;
  6091. int type;
  6092. char *data;
  6093. int datalen;
  6094. struct rrec *newrr;
  6095. char *buf;
  6096. int buflen;
  6097.  
  6098.  Parameter      Description 
  6099.  
  6100.  op             The usual type is QUERY, but you can set the parameter to any 
  6101.                 query type defined in the <ARPA\NAMESER.H> header file. 
  6102.  
  6103.  dname          Pointer to the domain name. If dname points to a single label 
  6104.                 and the RES_DEFNAMES bit in the _res structure defined in the 
  6105.                 <RESOLV.H> header file is set, the call appends dname to the 
  6106.                 current domain name. The current domain name is defined in the 
  6107.                 ETC\RESOLV file. 
  6108.  
  6109.  class          One of the following values: 
  6110.  
  6111.                 C_IN           ARPA internet 
  6112.                 C_CHAOS        Chaos network at MIT 
  6113.  
  6114.  type           One of the following type values for resources and queries: 
  6115.  
  6116.                 T_A            Host address 
  6117.                 T_NS           Authoritative server 
  6118.                 T_MD           Mail destination 
  6119.                 T_MF           Mail forwarder 
  6120.                 T_CNAME        Canonical name 
  6121.                 T_SOA          Start of authority zone 
  6122.                 T_MB           Mailbox domain name 
  6123.                 T_MG           Mail group member 
  6124.                 T_MR           Mail rename name 
  6125.                 T_NULL         NULL resource record 
  6126.                 T_WKS          Well-known service 
  6127.                 T_PTR          Domain name pointer 
  6128.                 T_HINFO        Host information 
  6129.                 T_MINFO        Mailbox information 
  6130.                 T_MX           Mail routing information 
  6131.                 T_UINFO        User information 
  6132.                 T_UID          User ID 
  6133.                 T_GID          Group ID 
  6134.  
  6135.  data           Pointer to the data sent to the name server as a search key 
  6136.  
  6137.  datalen        Size of the data parameter in bytes 
  6138.  
  6139.  newrr          Reserved. Unused parameter. 
  6140.  
  6141.  buf            Pointer to the query message 
  6142.  
  6143.  buflen         Length of the buffer in bytes pointed to by the buf parameter 
  6144.  
  6145.  Description:  This call makes a query message for the name servers in the 
  6146.  internet domain and puts that query message in the location pointed by the buf 
  6147.  parameter. It uses global _res structure, which is defined in the <RESOLV.H> 
  6148.  header file. 
  6149.  
  6150.  Return Value:  If it succeeds, the res_mkquery() call returns the size of the 
  6151.  query.  If the query is larger than the value of buflen, the call fails and 
  6152.  returns a value of -1. 
  6153.  
  6154.  
  6155. ΓòÉΓòÉΓòÉ 7.35. res_send() ΓòÉΓòÉΓòÉ
  6156.  
  6157. Sends a query to a local name server. 
  6158.  
  6159. #include <types.h>
  6160. #include <netinet\in.h>
  6161. #include <arpa\nameser.h>
  6162. #include <resolv.h>
  6163.  
  6164. int re_send(msg, msglen, ans, anslen)
  6165. char *msg;
  6166. int msglen;
  6167. char *ans;
  6168. int anslen;
  6169.  
  6170.  Parameter      Description 
  6171.  
  6172.  msg            Pointer to the beginning of a message 
  6173.  
  6174.  msglen         Length of the buffer in bytes pointed to by the msg parameter 
  6175.  
  6176.  ans            Pointer to the location where the received response is stored 
  6177.  
  6178.  anslen         Length of the buffer in bytes pointed by the ans parameter 
  6179.  
  6180.  Description:  This call sends a query to the local name server and calls the 
  6181.  res_init() call if the RES_INIT option of the global _res structure is not 
  6182.  set. It also handles timeouts and retries. It uses the global _res structure, 
  6183.  which is defined in the <RESOLV.H> header file. 
  6184.  
  6185.  Return Value:  If it succeeds, the call returns the length of the message. If 
  6186.  it fails, the call returns a value of -1. 
  6187.  
  6188.  
  6189. ΓòÉΓòÉΓòÉ 7.36. sethostent() ΓòÉΓòÉΓòÉ
  6190.  
  6191. Opens and rewinds the HOSTS file. 
  6192.  
  6193. #include <stdio.h>
  6194.  
  6195. void sethostent(stayopen)
  6196. int stayopen;
  6197.  
  6198.  Parameter      Description 
  6199.  
  6200.  stayopen       Allows the ETC\HOSTS file to stay open after each call 
  6201.  
  6202.  Description:  This call opens and rewinds the ETC\HOSTS file. If the stayopen 
  6203.  parameter is nonzero, the ETC\HOSTS file stays open after each of the gethost 
  6204.  calls. 
  6205.  
  6206.  Return Value: The sethostent() call returns a global pointer to the FILE 
  6207.  structure defined in the <STDIO.H> header file. A NULL pointer indicates an 
  6208.  error or EOF. 
  6209.  
  6210.  
  6211. ΓòÉΓòÉΓòÉ 7.37. setnetent() ΓòÉΓòÉΓòÉ
  6212.  
  6213. Opens and rewinds the NETWORKS file. 
  6214.  
  6215. #include <stdio.h>
  6216.  
  6217. void setnetent(stayopen)
  6218. int stayopen;
  6219.  
  6220.  Parameter      Description 
  6221.  
  6222.  stayopen       Allows the ETC\NETWORKS file to stay open after each call 
  6223.  
  6224.  Description:  This call opens and rewinds the ETC\NETWORKS file, which 
  6225.  contains information about known networks.  If the stayopen parameter is 
  6226.  nonzero, the ETC\NETWORKS file stays open after each of the getnet calls. 
  6227.  
  6228.  Return Value: The setnetent() call returns a global pointer to the FILE 
  6229.  structure defined in the <STDIO.H> header file. A NULL pointer indicates an 
  6230.  error or EOF. 
  6231.  
  6232.  
  6233. ΓòÉΓòÉΓòÉ 7.38. setprotoent() ΓòÉΓòÉΓòÉ
  6234.  
  6235. Opens and rewinds the PROTOCOL file. 
  6236.  
  6237. #include <stdio.h>
  6238.  
  6239. void setprotoent(stayopen)
  6240. int stayopen;
  6241.  
  6242.  Parameter      Description 
  6243.  
  6244.  stayopen       Allows the ETC\PROTOCOL file to stay open after each call 
  6245.  
  6246.  Description:  This call opens and rewinds the ETC\PROTOCOL file, which 
  6247.  contains information about known protocols. If the stayopen parameter is 
  6248.  nonzero, the ETC\PROTOCOL file stays open after each of the getproto calls. 
  6249.  
  6250.  Return Value: The setprotoent() call returns a global pointer to the FILE 
  6251.  structure defined in the <STDIO.H> header file. A NULL pointer indicates an 
  6252.  error or EOF. 
  6253.  
  6254.  
  6255. ΓòÉΓòÉΓòÉ 7.39. setservent() ΓòÉΓòÉΓòÉ
  6256.  
  6257. Opens and rewinds the SERVICES file. 
  6258.  
  6259. #include <stdio.h>
  6260.  
  6261. void setservent(stayopen)
  6262. int stayopen;
  6263.  
  6264.  Parameter      Description 
  6265.  
  6266.  stayopen       Allows the ETC\SERVICES file to stay open after each call 
  6267.  
  6268.  Description:  This call opens and rewinds the ETC\SERVICES file, which 
  6269.  contains information about known services and well-known ports. If the 
  6270.  stayopen parameter is nonzero, the ETC\SERVICES file stays open after each of 
  6271.  the getserv calls. 
  6272.  
  6273.  Return Value: The setservent() call returns a global pointer to the FILE 
  6274.  structure defined in the <STDIO.H> header file. A NULL pointer indicates an 
  6275.  error or EOF. 
  6276.  
  6277.  
  6278. ΓòÉΓòÉΓòÉ 8. Socket Error Return Code Constants ΓòÉΓòÉΓòÉ
  6279.  
  6280. The following table provides the error constants set by socket calls. This 
  6281. table can be found in the <NERRNO.H> header file. For further system error 
  6282. return code numbers, refer to the compiler <ERRNO.H> header file. 
  6283.  
  6284. You can use the psock_errno() call to write short error messages to the 
  6285. standard error device. Refer to psock_errno() for additional information. 
  6286.  
  6287. #define SOCBASEERR              0
  6288.  
  6289. /*
  6290.  * SOCKET API definitions of error constants
  6291.  */
  6292.  
  6293. #define SOCEPERM              1          /* Not owner */
  6294. #define SOCESRCH              3          /* No such process */
  6295. #define SOCEINTR              4          /* Interrupted system call */
  6296. #define SOCENXIO              6          /* No such device or address */
  6297. #define SOCEBADF              9          /* Bad file number */
  6298. #define SOCEACCES            13          /* Permission denied */
  6299. #define SOCEFAULT            14          /* Bad address */
  6300. #define SOCEINVAL            22          /* Invalid argument */
  6301. #define SOCEMFILE            24          /* Too many open files */
  6302. #define SOCEPIPE             32          /* Broken pipe */
  6303.  
  6304. #define SOCEOS2ERR          100          /* OS/2 Error */
  6305.  
  6306.  
  6307. /*
  6308.  * Networking-related BSD errno values.
  6309.  */
  6310.  
  6311. #define EWOULDBLOCK          35          /* Operation would block */
  6312. #define EINPROGRESS          36          /* Operation now in progress */
  6313. #define EALREADY             37          /* Operation already in progress */
  6314. #define ENOTSOCK             38          /* Socket operation on nonsocket */
  6315. #define EDESTADDRREQ         39          /* Destination address required */
  6316. #define EMSGSIZE             40          /* Message too long */
  6317. #define EPROTOTYPE           41          /* Protocol wrong type for socket */
  6318. #define ENOPROTOOPT          42          /* Protocol not available */
  6319. #define EPROTONOSUPPORT      43          /* Protocol not supported */
  6320. #define ESOCKTNOSUPPORT      44          /* Socket type not supported */
  6321. #define EOPNOTSUPP           45          /* Operation not supported on socket */
  6322. #define EPFNOSUPPORT         46          /* Protocol family not supported */
  6323. #define EAFNOSUPPORT         47          /* Address family not supported by protocol family *     /
  6324. #define EADDRINUSE           48          /* Address already in use */
  6325. #define EADDRNOTAVAIL        49          /* Cannot assign requested address */
  6326. #define ENETDOWN             50          /* Network is down */
  6327. #define ENETUNREACH          51          /* Network is unreachable */
  6328. #define ENETRESET            52          /* Network dropped connection on reset */
  6329. #define ECONNABORTED         53          /* Software caused connection to stop */
  6330. #define ECONNRESET           54          /* Connection reset by peer */
  6331. #define ENOBUFS              55          /* No buffer space available */
  6332. #define EISCONN              56          /* Socket is already connected */
  6333. #define ENOTCONN             57          /* Socket is not connected */
  6334. #define ESHUTDOWN            58          /* Cannot send after socket shutdown */
  6335. #define ETOOMANYREFS         59          /* Too many references: cannot splice */
  6336. #define ETIMEDOUT            60          /* Connection timed out */
  6337. #define ECONNREFUSED         61          /* Connection refused */
  6338. #define ELOOP                62          /* Too many levels of symbolic links */
  6339. #define ENAMETOOLONG         63          /* File name too long */
  6340. #define EHOSTDOWN            64          /* Host is down */
  6341. #define EHOSTUNREACH         65          /* No route to host */
  6342. #define ENOTEMPTY            66          /* Directory not empty */
  6343.  
  6344. /*
  6345.  * OS/2 SOCKET API definitions of regular BSD error constants
  6346.  */
  6347.  
  6348. #define SOCEWOULDBLOCK          EWOULDBLOCK
  6349. #define SOCEINPROGRESS          EINPROGRESS
  6350. #define SOCEALREADY             EALREADY
  6351. #define SOCENOTSOCK             ENOTSOCK
  6352. #define SOCEDESTADDRREQ         EDESTADDRREQ
  6353. #define SOCEMSGSIZE             EMSGSIZE
  6354. #define SOCEPROTOTYPE           EPROTOTYPE
  6355. #define SOCENOPROTOOPT          ENOPROTOOPT
  6356. #define SOCEPROTONOSUPPORT      EPROTONOSUPPORT
  6357. #define SOCESOCKTNOSUPPORT      ESOCKTNOSUPPORT
  6358. #define SOCEOPNOTSUPP           EOPNOTSUPP
  6359. #define SOCEPFNOSUPPORT         EPFNOSUPPORT
  6360. #define SOCEAFNOSUPPORT         EAFNOSUPPORT
  6361. #define SOCEADDRINUSE           EADDRINUSE
  6362. #define SOCEADDRNOTAVAIL        EADDRNOTAVAIL
  6363. #define SOCENETDOWN             ENETDOWN
  6364. #define SOCENETUNREACH          ENETUNREACH
  6365. #define SOCENETRESET            ENETRESET
  6366. #define SOCECONNABORTED         ECONNABORTED
  6367. #define SOCECONNRESET           ECONNRESET
  6368. #define SOCENOBUFS              ENOBUFS
  6369. #define SOCEISCONN              EISCONN
  6370. #define SOCENOTCONN             ENOTCONN
  6371. #define SOCESHUTDOWN            ESHUTDOWN
  6372. #define SOCETOOMANYREFS         ETOOMANYREFS
  6373. #define SOCETIMEDOUT            ETIMEDOUT
  6374. #define SOCECONNREFUSED         ECONNREFUSED
  6375. #define SOCELOOP                ELOOP
  6376. #define SOCENAMETOOLONG         ENAMETOOLONG
  6377. #define SOCEHOSTDOWN            EHOSTDOWN
  6378. #define SOCEHOSTUNREACH         EHOSTUNREACH
  6379. #define SOCENOTEMPTY            ENOTEMPTY
  6380.  
  6381.  
  6382. ΓòÉΓòÉΓòÉ 9. Well-Known Port Assignments ΓòÉΓòÉΓòÉ
  6383.  
  6384. The following table is a list of the well-known ports supported by TCP/IP. It 
  6385. provides the port number, keyword, and a description of the reserved port 
  6386. assignment. Port numbers of less than 1024 are reserved for system 
  6387. applications. You can also find a list of some of these well-known port numbers 
  6388. in the ETC\SERVICES file. 
  6389.  
  6390. TCP Well-Known Port Assignments 
  6391.  
  6392. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  6393. Γöé Table 21. TCP Well-Known Port Assignments                  Γöé
  6394. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6395. Γöé PORT   Γöé      Γöé              Γöé              Γöé
  6396. Γöé NUMBER  Γöé KEYWORD  Γöé RESERVED FOR        Γöé SERVICES DESCRIPTION    Γöé
  6397. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6398. Γöé 0    Γöé      Γöé reserved          Γöé              Γöé
  6399. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6400. Γöé 5    Γöé RJE    Γöé remote job entry      Γöé remote job entry      Γöé
  6401. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6402. Γöé 7    Γöé ECHO    Γöé echo            Γöé echo            Γöé
  6403. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6404. Γöé 9    Γöé DISCARD  Γöé discard          Γöé sink null         Γöé
  6405. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6406. Γöé 11    Γöé SYSTAT   Γöé active users        Γöé active users        Γöé
  6407. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6408. Γöé 13    Γöé DAYTIME  Γöé daytime          Γöé daytime          Γöé
  6409. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6410. Γöé 15    Γöé NETSTAT  Γöé Netstat          Γöé who is up or Netstat    Γöé
  6411. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6412. Γöé 19    Γöé CHARGEN  Γöé ttytst source       Γöé character generator    Γöé
  6413. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6414. Γöé 21    Γöé FTP    Γöé FTP            Γöé File Transfer Protocol   Γöé
  6415. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6416. Γöé 23    Γöé TELNET   Γöé Telnet           Γöé Telnet           Γöé
  6417. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6418. Γöé 25    Γöé SMTP    Γöé mail            Γöé Simple Mail Transfer Pro- Γöé
  6419. Γöé     Γöé      Γöé              Γöé tocol           Γöé
  6420. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6421. Γöé 37    Γöé TIME    Γöé timeserver         Γöé timeserver         Γöé
  6422. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6423. Γöé 39    Γöé RLP    Γöé resource          Γöé Resource Location Pro-   Γöé
  6424. Γöé     Γöé      Γöé              Γöé tocol           Γöé
  6425. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6426. Γöé 42    Γöé NAMESERVERΓöé name            Γöé host name server      Γöé
  6427. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6428. Γöé 43    Γöé NICNAME  Γöé who is           Γöé who is           Γöé
  6429. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6430. Γöé 53    Γöé DOMAIN   Γöé name server        Γöé domain name server     Γöé
  6431. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6432. Γöé 57    Γöé MTP    Γöé private terminal access  Γöé private terminal access  Γöé
  6433. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6434. Γöé 69    Γöé TFTP    Γöé TFTP            Γöé Trivial File Transfer   Γöé
  6435. Γöé     Γöé      Γöé              Γöé Protocol          Γöé
  6436. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6437. Γöé 77    Γöé      Γöé netrjs           Γöé any private RJE service  Γöé
  6438. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6439. Γöé 79    Γöé FINGER   Γöé finger           Γöé finger           Γöé
  6440. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6441. Γöé 87    Γöé LINK    Γöé ttylink          Γöé any private terminal link Γöé
  6442. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6443. Γöé 95    Γöé SUPDUP   Γöé supdup           Γöé SUPDUP Protocol      Γöé
  6444. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6445. Γöé 101   Γöé HOSTNAME  Γöé hostname          Γöé nic hostname server,    Γöé
  6446. Γöé     Γöé      Γöé              Γöé usually from SRI-NIC    Γöé
  6447. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6448. Γöé 109   Γöé POP    Γöé postoffice         Γöé Post Office Protocol    Γöé
  6449. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6450. Γöé 111   Γöé SUNRPC   Γöé sunrpc           Γöé Sun remote procedure call Γöé
  6451. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6452. Γöé 113   Γöé AUTH    Γöé authentication       Γöé authentication service   Γöé
  6453. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6454. Γöé 115   Γöé SFTP    Γöé sftp            Γöé Simple File Transfer Pro- Γöé
  6455. Γöé     Γöé      Γöé              Γöé tocol           Γöé
  6456. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6457. Γöé 117   Γöé UUCP-PATH Γöé UUCP path service     Γöé UUCP path service     Γöé
  6458. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6459. Γöé 119   Γöé UNTP    Γöé readnews untp       Γöé USENET News Transfer Pro- Γöé
  6460. Γöé     Γöé      Γöé              Γöé tocol           Γöé
  6461. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6462. Γöé 123   Γöé NTP    Γöé NTP            Γöé Network Time Protocol   Γöé
  6463. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6464. Γöé 160   Γöé      Γöé reserved          Γöé              Γöé
  6465. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6466. Γöé 161   Γöé SNMP    Γöé SNMP Agent         Γöé SNMP Agent receives    Γöé
  6467. Γöé     Γöé      Γöé              Γöé packets          Γöé
  6468. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6469. Γöé 162   Γöé SNMPTRAP  Γöé SNMP Client        Γöé SNMP Client receives SNMP Γöé
  6470. Γöé     Γöé      Γöé              Γöé TRAPs           Γöé
  6471. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  6472. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  6473. Γöé Table 21. TCP Well-Known Port Assignments                  Γöé
  6474. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6475. Γöé PORT   Γöé      Γöé              Γöé              Γöé
  6476. Γöé NUMBER  Γöé KEYWORD  Γöé RESERVED FOR        Γöé SERVICES DESCRIPTION    Γöé
  6477. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6478. Γöé 163-223 Γöé      Γöé reserved          Γöé              Γöé
  6479. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6480. Γöé 449   Γöé AS-SVRMAP Γöé mapper function for    Γöé servers for signon,    Γöé
  6481. Γöé     Γöé      Γöé AS/400 servers       Γöé central management,    Γöé
  6482. Γöé     Γöé      Γöé              Γöé network print, database,  Γöé
  6483. Γöé     Γöé      Γöé              Γöé stream file, data queue,  Γöé
  6484. Γöé     Γöé      Γöé              Γöé and remote command and   Γöé
  6485. Γöé     Γöé      Γöé              Γöé distributed program    Γöé
  6486. Γöé     Γöé      Γöé              Γöé calls.           Γöé
  6487. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6488. Γöé 712   Γöé VEXEC   Γöé vice-exec         Γöé Andrew File System     Γöé
  6489. Γöé     Γöé      Γöé              Γöé authenticated service   Γöé
  6490. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6491. Γöé 713   Γöé VLOGIN   Γöé vice-login         Γöé Andrew File System     Γöé
  6492. Γöé     Γöé      Γöé              Γöé authenticated service   Γöé
  6493. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6494. Γöé 714   Γöé VSHELL   Γöé vice-shell         Γöé Andrew File System     Γöé
  6495. Γöé     Γöé      Γöé              Γöé authenticated service   Γöé
  6496. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6497. Γöé 2001   Γöé FILESRV  Γöé              Γöé Andrew File System     Γöé
  6498. Γöé     Γöé      Γöé              Γöé service          Γöé
  6499. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6500. Γöé 2106   Γöé VENUS.ITC Γöé              Γöé Andrew File System     Γöé
  6501. Γöé     Γöé      Γöé              Γöé service, for the Venus   Γöé
  6502. Γöé     Γöé      Γöé              Γöé process          Γöé
  6503. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  6504.  
  6505. UDP Well-Known Port Assignments 
  6506.  
  6507. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  6508. Γöé Table 22. UDP Well-Known Port Assignments                  Γöé
  6509. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6510. Γöé PORT    Γöé      Γöé           Γöé                 Γöé
  6511. Γöé NUMBER   Γöé KEYWORD  Γöé RESERVED FOR    Γöé SERVICES DESCRIPTION      Γöé
  6512. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6513. Γöé 0     Γöé      Γöé reserved      Γöé                 Γöé
  6514. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6515. Γöé 5     Γöé RJE    Γöé remote job entry  Γöé remote job entry        Γöé
  6516. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6517. Γöé 7     Γöé ECHO    Γöé echo        Γöé echo              Γöé
  6518. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6519. Γöé 9     Γöé DISCARD  Γöé discard       Γöé sink null            Γöé
  6520. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6521. Γöé 11     Γöé USERS   Γöé active users    Γöé active users          Γöé
  6522. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6523. Γöé 13     Γöé DAYTIME  Γöé daytime       Γöé daytime             Γöé
  6524. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6525. Γöé 15     Γöé NETSTAT  Γöé Netstat       Γöé Netstat             Γöé
  6526. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6527. Γöé 19     Γöé CHARGEN  Γöé ttytst source    Γöé character generator       Γöé
  6528. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6529. Γöé 37     Γöé TIME    Γöé timeserver     Γöé timeserver           Γöé
  6530. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6531. Γöé 39     Γöé RLP    Γöé resource      Γöé Resource Location Protocol   Γöé
  6532. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6533. Γöé 42     Γöé NAMESERVERΓöé name        Γöé host name server        Γöé
  6534. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6535. Γöé 43     Γöé NICNAME  Γöé who is       Γöé who is             Γöé
  6536. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6537. Γöé 53     Γöé DOMAIN   Γöé name server     Γöé domain name server       Γöé
  6538. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6539. Γöé 67     Γöé BOOTPS   Γöé bootps       Γöé bootp server          Γöé
  6540. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6541. Γöé 68     Γöé BOOTPC   Γöé bootpc       Γöé bootp client          Γöé
  6542. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6543. Γöé 69     Γöé TFTP    Γöé TFTP        Γöé Trivial File Transfer Protocol Γöé
  6544. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6545. Γöé 75     Γöé      Γöé           Γöé any private dial out service  Γöé
  6546. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6547. Γöé 77     Γöé      Γöé netrjs       Γöé any private RJE service     Γöé
  6548. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6549. Γöé 79     Γöé FINGER   Γöé finger       Γöé finger             Γöé
  6550. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6551. Γöé 111    Γöé SUNRPC   Γöé sunrpc       Γöé Sun remote procedure call    Γöé
  6552. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6553. Γöé 123    Γöé NTP    Γöé NTP         Γöé Network Time Protocol      Γöé
  6554. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6555. Γöé 135    Γöé LLBD    Γöé NCS LLBD      Γöé NCS local location broker    Γöé
  6556. Γöé      Γöé      Γöé           Γöé daemon             Γöé
  6557. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6558. Γöé 160-223  Γöé      Γöé reserved      Γöé                 Γöé
  6559. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6560. Γöé 531    Γöé RVD-CONTROΓöé           Γöé rvd control port        Γöé
  6561. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6562. Γöé 2001    Γöé RAUTH2   Γöé           Γöé Andrew File System service,   Γöé
  6563. Γöé      Γöé      Γöé           Γöé for the Venus process      Γöé
  6564. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6565. Γöé 2002    Γöé RFILEBULK Γöé           Γöé Andrew File System service,   Γöé
  6566. Γöé      Γöé      Γöé           Γöé for the Venus process      Γöé
  6567. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6568. Γöé 2003    Γöé RFILESRV  Γöé           Γöé Andrew File System service,   Γöé
  6569. Γöé      Γöé      Γöé           Γöé for the Venus process      Γöé
  6570. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6571. Γöé 2018    Γöé CONSOLE  Γöé           Γöé Andrew File System service   Γöé
  6572. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6573. Γöé 2115    Γöé ROPCONS  Γöé           Γöé Andrew File System service,   Γöé
  6574. Γöé      Γöé      Γöé           Γöé for the Venus process      Γöé
  6575. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6576. Γöé 2131    Γöé RUPDSRV  Γöé           Γöé assigned in pairs; bulk must  Γöé
  6577. Γöé      Γöé      Γöé           Γöé be SRV +1            Γöé
  6578. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6579. Γöé 2132    Γöé RUPDBULK  Γöé           Γöé assigned in pairs; bulk must  Γöé
  6580. Γöé      Γöé      Γöé           Γöé be SRV +1            Γöé
  6581. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6582. Γöé 2133    Γöé RUPDSRV1  Γöé           Γöé assigned in pairs; bulk must  Γöé
  6583. Γöé      Γöé      Γöé           Γöé be SRV +1            Γöé
  6584. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6585. Γöé 2134    Γöé RUPDBULK1 Γöé           Γöé assigned in pairs; bulk must  Γöé
  6586. Γöé      Γöé      Γöé           Γöé be SRV +1            Γöé
  6587. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  6588.  
  6589.  
  6590. ΓòÉΓòÉΓòÉ 10. Notices ΓòÉΓòÉΓòÉ
  6591.  
  6592. First Edition (June, 1996) 
  6593.  
  6594. The following paragraph does not apply to the United Kingdom or any country 
  6595. where such provisions are inconsistent with local law:  INTERNATIONAL BUSINESS 
  6596. MACHINES CORPORATION PROVIDES THIS PUBLICATION "AS IS" WITHOUT WARRANTY OF ANY 
  6597. KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
  6598. WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Some states 
  6599. do not allow disclaimer of express or implied warranties in certain 
  6600. transactions, therefore, this statement may not apply to you. 
  6601.  
  6602. This publication could include technical inaccuracies or typographical errors. 
  6603. Changes are periodically made to the information herein; these changes will be 
  6604. incorporated in new editions of the publication. IBM may make improvements 
  6605. and/or changes in the product(s) and/or the program(s) described in this 
  6606. publication at any time. 
  6607.  
  6608. It is possible that this publication may contain reference to, or information 
  6609. about, IBM products (machines and programs), programming, or services that are 
  6610. not announced in your country.  Such references or information must not be 
  6611. construed to mean that IBM intends to announce such IBM products, programming, 
  6612. or services in your country. 
  6613.  
  6614. Requests for technical information about IBM products should be made to your 
  6615. IBM authorized reseller or IBM marketing representative. 
  6616.  
  6617.  
  6618. ΓòÉΓòÉΓòÉ 10.1. Copyright Notices ΓòÉΓòÉΓòÉ
  6619.  
  6620. COPYRIGHT LICENSE: This publication contains printed sample application 
  6621. programs in source language, which illustrate OS/2 programming techniques. You 
  6622. may copy, modify, and distribute these sample programs in any form without 
  6623. payment to IBM, for the purposes of developing, using, marketing or 
  6624. distributing application programs conforming to the OS/2 application 
  6625. programming interface. 
  6626.  
  6627. Each copy of any portion of these sample programs or any derivative work, which 
  6628. is distributed to others, must include a copyright notice as follows: "(C) 
  6629. (your company name) (year).  All rights reserved." 
  6630.  
  6631. (C)Copyright International Business Machines Corporation 1993, 1996.  All 
  6632. rights reserved. 
  6633. Note to U.S. Government Users - Documentation related to restricted rights - 
  6634. Use, duplication or disclosure is subject to restrictions set forth in GSA ADP 
  6635. Schedule Contract with IBM Corp. 
  6636.  
  6637.  
  6638. ΓòÉΓòÉΓòÉ 10.2. Disclaimers ΓòÉΓòÉΓòÉ
  6639.  
  6640. References in this publication to IBM products, programs, or services do not 
  6641. imply that IBM intends to make these available in all countries in which IBM 
  6642. operates. Any reference to an IBM product, program or service is not intended 
  6643. to state or imply that only IBM's product, program, or service may be used. Any 
  6644. functionally equivalent product, program, or service that does not infringe any 
  6645. of IBM's intellectual property rights or other legally protectable rights may 
  6646. be used instead of the IBM product, program, or service. Evaluation and 
  6647. verification of operation in conjunction with other products, programs, or 
  6648. services, except those expressly designated by IBM, are the user's 
  6649. responsibility. 
  6650.  
  6651. IBM may have patents or pending patent applications covering subject matter in 
  6652. this document. The furnishing of this document does not give you any license to 
  6653. these patents. You can send license inquiries, in writing, to the IBM Director 
  6654. of Licensing, IBM Corporation, 500 Columbus Avenue, Thornwood NY 10594, U.S.A. 
  6655.  
  6656. Licensees of this program who wish to have information about it for the purpose 
  6657. of enabling:  (i) the exchange of information between independently created 
  6658. programs and other programs (including this one) and (ii) the mutual use of the 
  6659. information which has been exchanged, should contact IBM Corporation, 
  6660. Department RM1A, 1000 N.W. 51st Street, Boca Raton, FL 33431, U.S.A.  Such 
  6661. information may be available, subject to appropriate terms and conditions, 
  6662. including in some cases, payment of a fee.